publish 638 B

123456789101112131415161718192021
  1. #!/usr/bin/env bash
  2. set -euo pipefail
  3. # Get the latest Git tag
  4. latest_tag=$(git tag --sort=committerdate | grep -E '^vscode-v[0-9]+\.[0-9]+\.[0-9]+$' | tail -1)
  5. if [ -z "$latest_tag" ]; then
  6. echo "No tags found"
  7. exit 1
  8. fi
  9. echo "Latest tag: $latest_tag"
  10. version=$(echo "$latest_tag" | sed 's/^vscode-v//')
  11. echo "Latest version: $version"
  12. # package-marketplace
  13. vsce package --no-git-tag-version --no-update-package-json --no-dependencies --skip-license -o dist/opencode.vsix "$version"
  14. # publish-marketplace
  15. vsce publish --packagePath dist/opencode.vsix
  16. # publish-openvsx
  17. npx ovsx publish dist/opencode.vsix -p "$OPENVSX_TOKEN"