diff --git a/.github/workflows/onPROnDevelop.yml b/.github/workflows/onPROnDevelop.yml index 4879810..ea7e4f4 100644 --- a/.github/workflows/onPROnDevelop.yml +++ b/.github/workflows/onPROnDevelop.yml @@ -16,7 +16,7 @@ jobs: - name: Setup Node.js uses: actions/setup-node@v4 with: - node-version: '20' + node-version: '24' - name: Install dependencies run: npm install diff --git a/.github/workflows/release.yml b/.github/workflows/release.yml index 8a09709..429aa90 100644 --- a/.github/workflows/release.yml +++ b/.github/workflows/release.yml @@ -39,7 +39,7 @@ jobs: - name: Setup Node.js uses: actions/setup-node@v4 with: - node-version: '20' + node-version: '24' - name: Install deps run: npm install @@ -47,41 +47,45 @@ jobs: - name: Build Blapy2 run: npm run build - - name: Commit built file + - name: Commit built files run: | git config user.name "github-actions[bot]" git config user.email "github-actions[bot]@users.noreply.github.com" - git add dist/blapy2.js -f - git add dist/Blapymotion.js -f - git add dist/BlapySocket.js -f - git commit -m "chore: build dist/blapy2.js [skip ci]" || echo "no changes" + git add -f dist/blapy.umd.js dist/blapy.mjs dist/BlapyMotion.js dist/BlapySocket.js + git commit -m "chore: build dist [skip ci]" || echo "no changes" git push - name: Install jq (for reading version from package.json) run: sudo apt-get update && sudo apt-get install -y jq - - name: Bump version + tag + - name: Create tag from package.json version id: version run: | - LAST_VERSION=$(git tag --sort=-v:refname | tail -n 1) - if [[ "$LAST_VERSION" =~ ^v([0-9]+)\.([0-9]+)\.([0-9]+)$ ]]; then - MAJOR=${BASH_REMATCH[1]} - MINOR=${BASH_REMATCH[2]} - PATCH=${BASH_REMATCH[3]} - NEW_VERSION="v$(jq -r .version package.json)" - else - NEW_VERSION="v0.0.1" - fi - echo "New version: $NEW_VERSION" + VERSION=$(jq -r .version package.json) + NEW_VERSION="v$VERSION" + echo "new_version=$NEW_VERSION" >> $GITHUB_OUTPUT - git tag $NEW_VERSION - git push origin $NEW_VERSION + + if git tag -l | grep -qx "$NEW_VERSION"; then + echo "Tag already exists: $NEW_VERSION" + echo "tag_created=false" >> $GITHUB_OUTPUT + exit 0 + fi + + git tag "$NEW_VERSION" + git push origin "$NEW_VERSION" + echo "tag_created=true" >> $GITHUB_OUTPUT - name: Create GitHub Release + if: steps.version.outputs.tag_created == 'true' uses: softprops/action-gh-release@v1 with: tag_name: ${{ steps.version.outputs.new_version }} name: Release ${{ steps.version.outputs.new_version }} - files: dist/blapy2.js + files: | + dist/blapy.umd.js + dist/blapy.mjs + dist/BlapyMotion.js + dist/BlapySocket.js env: - GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }} + GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }} \ No newline at end of file diff --git a/.gitignore b/.gitignore index 9c8acaa..b98ee0d 100644 --- a/.gitignore +++ b/.gitignore @@ -1,9 +1,11 @@ old/** node_modules/** -docker-compose.yml .idea/** dist/** test-results/** CLAUDE.md **/node_modules/ -dist/blapy2.js \ No newline at end of file +dist/blapy2.js +bun.lockb +src/old +/Blapy2/ diff --git a/.prettierrc b/.prettierrc index e5ed4be..92beac4 100644 --- a/.prettierrc +++ b/.prettierrc @@ -1,6 +1,6 @@ { "endOfLine": "lf", - "semi": false, + "semi": true, "singleQuote": true, "tabWidth": 2, "trailingComma": "es5" diff --git a/Blapy.js b/Blapy.js deleted file mode 120000 index 2bc84d0..0000000 --- a/Blapy.js +++ /dev/null @@ -1 +0,0 @@ -dist/blapy2.js \ No newline at end of file diff --git a/LICENSE b/LICENSE index 092b62c..af502a7 100644 --- a/LICENSE +++ b/LICENSE @@ -7,7 +7,7 @@ * Abstract : transform your standard website into a web app * Remark : * ----------------------------------------------------------------------------------------- - * @copyright : Intersel 2015-2025 + * @copyright : Intersel 2015-2026 * @contributors : * - Emmanuel Podvin - github@intersel.fr * ----------------------------------------------------------------------------------------- diff --git a/demos/bootstrap-four-column-gallery/index.html b/demos/bootstrap-four-column-gallery/index.html index 71df7ba..2d6b646 100644 --- a/demos/bootstrap-four-column-gallery/index.html +++ b/demos/bootstrap-four-column-gallery/index.html @@ -96,20 +96,17 @@
Clique sur une demo pour l'ouvrir. Le tag indique si elle utilise déjà le build moderne (blapy.umd.js).