diff --git a/.github/workflows/build.yml b/.github/workflows/build.yml index 8c56f4732..b350812a4 100644 --- a/.github/workflows/build.yml +++ b/.github/workflows/build.yml @@ -3,6 +3,13 @@ on: push: branches: - main +# Serialize runs: concurrent runs finish in arbitrary order, and an older +# commit's run finishing last would overwrite a newer sync (e.g. revert a +# release). Only the newest pending run is kept, which is fine since it +# generates from the latest main. +concurrency: + group: ${{ github.workflow }}-${{ github.ref }} + cancel-in-progress: false jobs: build-go: runs-on: ubuntu-latest @@ -64,7 +71,7 @@ jobs: # Verify the generated CLI compiles against the freshly generated go # client, so this does not depend on a released phrase-go version # that may lag behind the spec. - (cd ./clients/cli && go mod edit -replace github.com/phrase/phrase-go/v4=../go && go build . && go mod edit -dropreplace github.com/phrase/phrase-go/v4) + (cd ./clients/cli && go mod edit -replace github.com/phrase/phrase-go/v4=../go && go build -o /dev/null . && go mod edit -dropreplace github.com/phrase/phrase-go/v4) git clone https://$API_TOKEN_GITHUB@github.com/phrase/phrase-cli.git clones/cli &> /dev/null rsync -avI --delete --exclude='.git/' clients/cli/ clones/cli cd clones/cli diff --git a/clients/cli/.gitignore b/clients/cli/.gitignore index 479e0b2c7..d3b018cbe 100644 --- a/clients/cli/.gitignore +++ b/clients/cli/.gitignore @@ -1 +1,2 @@ .phraseapp.yaml +/phrase-cli diff --git a/openapi-generator/java_lang.yaml b/openapi-generator/java_lang.yaml index 72969b676..b70b878f6 100644 --- a/openapi-generator/java_lang.yaml +++ b/openapi-generator/java_lang.yaml @@ -20,4 +20,5 @@ scmDeveloperConnection: scm:git:git@github.com:phrase/openapi.git scmUrl: https://github.com/phrase/strings-openapi java8: true dateLibrary: java8 +hideGenerationTimestamp: true templateDir: openapi-generator/templates/java diff --git a/openapi-generator/templates/ruby-client/model_doc.mustache b/openapi-generator/templates/ruby-client/model_doc.mustache index c2a790d9d..63cb29bd4 100644 --- a/openapi-generator/templates/ruby-client/model_doc.mustache +++ b/openapi-generator/templates/ruby-client/model_doc.mustache @@ -12,7 +12,7 @@ Name | Type | Description | Notes ```ruby require '{{moduleName}}' -instance = {{moduleName}}::{{classname}}.new({{#vars}}{{name}}: {{example}}{{^-last}}, +instance = {{moduleName}}::{{classname}}.new({{#vars}}{{name}}: {{#isBinary}}File.new('/path/to/file'){{/isBinary}}{{^isBinary}}{{example}}{{/isBinary}}{{^-last}}, {{/-last}}{{/vars}}) ```