docs: Add changelog entry for version 1.2.2, documenting Lazarus proj… #21
Workflow file for this run
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| # This is a basic workflow to help you get started with Actions | |
| name: Publish FpcToolKit | |
| # Controls when the workflow will run | |
| on: | |
| push: | |
| tags: | |
| - '*' | |
| # Allows you to run this workflow manually from the Actions tab | |
| workflow_dispatch: | |
| permissions: | |
| contents: write | |
| jobs: | |
| release: | |
| strategy: | |
| matrix: | |
| target: [win32-x64, linux-x64, linux-arm64, darwin-x64, darwin-arm64] | |
| runs-on: ubuntu-latest | |
| steps: | |
| - uses: actions/checkout@v2 | |
| - uses: actions/setup-node@v1 | |
| with: | |
| node-version: 20 | |
| - name: Install System Dependencies | |
| run: sudo apt-get update && sudo apt-get install -y libsecret-1-dev | |
| - name: Install the dependencies | |
| run: npm i | |
| - name: Install @vscode/vsce | |
| run: npm i -g @vscode/vsce | |
| - name: Prepare Binaries for ${{ matrix.target }} | |
| shell: bash | |
| run: | | |
| case "${{ matrix.target }}" in | |
| win32-x64) KEEP="win32" ;; | |
| linux-x64) KEEP="x86_64-linux" ;; | |
| linux-arm64) KEEP="aarch64-linux" ;; | |
| darwin-x64) KEEP="x86_64-darwin" ;; | |
| darwin-arm64) KEEP="x86_64-darwin" ;; # Apple Silicon continues to use Intel binary via Rosetta for now | |
| *) echo "Unknown target"; exit 1 ;; | |
| esac | |
| echo "Keeping only bin/$KEEP and common files..." | |
| # Delete all other architecture subdirectories in bin/ | |
| find bin -mindepth 1 -maxdepth 1 -type d ! -name "$KEEP" ! -name "debug" -exec rm -rf {} + | |
| - name: Build and Bundle | |
| run: npm run vscode:prepublish | |
| - name: Package Extension | |
| id: asset | |
| shell: bash | |
| run: | | |
| vsce package --target ${{ matrix.target }} | |
| echo "vsix_path=$(ls *.vsix)" >> $GITHUB_OUTPUT | |
| - name: Create or Update Release | |
| uses: softprops/action-gh-release@v1 | |
| if: startsWith(github.ref, 'refs/tags/') | |
| with: | |
| tag_name: ${{ github.ref_name }} | |
| name: Release ${{ github.ref_name }} | |
| files: ${{ steps.asset.outputs.vsix_path }} | |
| env: | |
| GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }} | |
| - name: Publish to Marketplace | |
| if: startsWith(github.ref, 'refs/tags/') | |
| run: vsce publish -p ${{ secrets.VSCE_PAT }} --target ${{ matrix.target }} | |