From 281b8ca7541790e10f1de7fa102265ef00d0d771 Mon Sep 17 00:00:00 2001 From: "d.strigo" Date: Wed, 25 Sep 2024 12:08:13 +0200 Subject: [PATCH] chore(docs): update docsDeploy.yml --- .github/workflows/docsDeploy.yml | 20 +++++++++----------- docs/main.ts | 1 + scripts/docs/build-docs.ts | 6 ------ 3 files changed, 10 insertions(+), 17 deletions(-) diff --git a/.github/workflows/docsDeploy.yml b/.github/workflows/docsDeploy.yml index 768498b5..a40b84b2 100644 --- a/.github/workflows/docsDeploy.yml +++ b/.github/workflows/docsDeploy.yml @@ -19,17 +19,15 @@ jobs: - uses: actions/checkout@v3 with: ref: demo - - name: Checkout private repo - uses: actions/checkout@v3 - with: - repository: akveo/ngx-admin - token: ${{ secrets.GH_PAT }} - - name: Deploy to GH pages - uses: nicoinch/ghpages@v3.0.0-alpha-1 - env: - GH_PAT: ${{ secrets.GH_PAT }} - - run: | - npm install --silent + - name: Install dependencies + run: npm install --silent + - name: Build project + run: | git config --global user.email "github-action@akveo.com" git config --global user.name "Github Action" npm run docs:gh-pages + - name: Deploy to GitHub Pages + uses: peaceiris/actions-gh-pages@v3 + with: + github_token: ${{ secrets.GH_PAT }} + publish_dir: ./docs/dist diff --git a/docs/main.ts b/docs/main.ts index e2b5bd9a..11f9f131 100644 --- a/docs/main.ts +++ b/docs/main.ts @@ -15,3 +15,4 @@ if (environment.production) { } platformBrowserDynamic().bootstrapModule(AppModule); + diff --git a/scripts/docs/build-docs.ts b/scripts/docs/build-docs.ts index 79f1b037..48a06f88 100644 --- a/scripts/docs/build-docs.ts +++ b/scripts/docs/build-docs.ts @@ -42,12 +42,6 @@ export interface Version { log(`Adding versions.json to ${OUT_DIR}`); await outputFile(join(OUT_DIR, 'versions.json'), jsonConfig); - - log(`Deploying to ghpages`); - await deploy(OUT_DIR); - - log(`Cleaning up working directory (${WORK_DIR})`); - await remove(WORK_DIR); }()); function ensureSingleCurrentVersion(versions: Version[]) {