Skip to content
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
30 changes: 29 additions & 1 deletion .github/workflows/npm.yml
Original file line number Diff line number Diff line change
Expand Up @@ -24,7 +24,24 @@ jobs:
- run: npm ci
- run: npm run build

- name: Check if pre-release and publish to NPM
- name: Build git-proxy-cli workspace
run: npm run build -w packages/git-proxy-cli

- name: Verify git-proxy-cli is in lockstep with the root package
run: |
ROOT_VERSION=$(node -p "require('./package.json').version")
CLI_VERSION=$(node -p "require('./packages/git-proxy-cli/package.json').version")
CLI_PIN=$(node -p "require('./packages/git-proxy-cli/package.json').dependencies['@finos/git-proxy']")
if [[ "$CLI_VERSION" != "$ROOT_VERSION" ]]; then
echo "Version mismatch: root=$ROOT_VERSION cli=$CLI_VERSION"
exit 1
fi
if [[ "$CLI_PIN" != "$ROOT_VERSION" ]]; then
echo "CLI pins @finos/git-proxy@$CLI_PIN but root is $ROOT_VERSION"
exit 1
fi

- name: Check if pre-release and publish @finos/git-proxy to NPM
run: |
VERSION=$(node -p "require('./package.json').version")
if [[ "$VERSION" == *"-"* ]]; then
Expand All @@ -34,3 +51,14 @@ jobs:
echo "Publishing stable release: $VERSION"
npm publish --access=public
fi

- name: Check if pre-release and publish @finos/git-proxy-cli to NPM
run: |
VERSION=$(node -p "require('./package.json').version")
if [[ "$VERSION" == *"-"* ]]; then
echo "Publishing pre-release: $VERSION"
npm publish -w packages/git-proxy-cli --access=public --tag rc
else
echo "Publishing stable release: $VERSION"
npm publish -w packages/git-proxy-cli --access=public
fi
5 changes: 5 additions & 0 deletions packages/git-proxy-cli/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,12 @@
"bin": {
"git-proxy-cli": "./dist/index.js"
},
"files": [
"dist"
],
"dependencies": {
"axios": "^1.18.1",
"yargs": "^18.0.0",
"@finos/git-proxy": "2.0.0"
},
"scripts": {
Expand Down
2 changes: 1 addition & 1 deletion website/docs/quickstart/installation.mdx
Original file line number Diff line number Diff line change
Expand Up @@ -28,7 +28,7 @@ npm install -g @finos/git-proxy@latest
To install a specific version of the GitProxy CLI, append the version to the end of the install command:

```bash
npm install -g @finos/git-proxy-cli@1.0.0
npm install -g @finos/git-proxy-cli@2.0.0
```

### Install a local checkout
Expand Down
Loading