mirror of
https://github.com/docsifyjs/docsify.git
synced 2026-10-16 20:21:38 +08:00
chore: Build and publish v4 lib/ and themes/ folders for backwards compatibility while users transition to v5. (#2667)
* Build and publish v4 lib/ and themes/ folders for backwards compatibility while users transition to v5. - add a script to build the legacy v4 lib/ and themes/ folders - append deprecation console warnings to the v4 JS files during the v4 build - add a script to clean v4 build outputs - hook the v4 build/clean scripts into the release.sh script - test the v4 build and clean in CI * fix: update repository field format in package.json --------- Co-authored-by: Luffy <52o@qq52o.cn>
This commit is contained in:
@@ -72,6 +72,25 @@ jobs:
|
||||
run: npx playwright install --with-deps
|
||||
- name: E2E Tests (Playwright)
|
||||
run: npm run test:e2e
|
||||
|
||||
# In the interest of not having to modify GitHub settings to update required
|
||||
# builds for passing, I stuck this test here.
|
||||
- name: Test v4 build
|
||||
run: |
|
||||
git fetch --tags
|
||||
npm run build:v4
|
||||
# ensure v4 build files exist:
|
||||
test -f lib/docsify.js
|
||||
test -f themes/pure.css
|
||||
# ensure no git changes after building v4:
|
||||
git diff --exit-code
|
||||
npm run clean:v4
|
||||
# ensure v4 build files are removed:
|
||||
test ! -f lib/docsify.js
|
||||
test ! -f themes/pure.css
|
||||
# ensure no git changes after cleaning v4:
|
||||
git diff --exit-code
|
||||
|
||||
- name: Store artifacts
|
||||
uses: actions/upload-artifact@v6
|
||||
if: failure()
|
||||
|
||||
Reference in New Issue
Block a user