Skip to content

Commit

Permalink
Cleanup build street
Browse files Browse the repository at this point in the history
  • Loading branch information
laurensWe committed Aug 22, 2024
1 parent 39a9533 commit 804e523
Show file tree
Hide file tree
Showing 2 changed files with 65 additions and 68 deletions.
131 changes: 65 additions & 66 deletions .github/workflows/continuous-deployment.yml
Original file line number Diff line number Diff line change
Expand Up @@ -101,69 +101,68 @@ jobs:

- name: "Continuous Integration: test"
run: pnpm run test

publish-website:
runs-on: ubuntu-latest
needs: build
if: github.ref == 'refs/heads/main'

environment:
name: github-pages
url: ${{ steps.deploy-pages.outputs.page_url }}

permissions:
pages: write
id-token: write

steps:
- name: Deploy to GitHub Pages
id: deploy-pages
uses: actions/deploy-pages@v4

publish-npm:
runs-on: ubuntu-latest
needs: [lint, test]
if: github.ref == 'refs/heads/main'

steps:
- name: Checkout release branch
uses: actions/checkout@v4
with:
token: ${{ secrets.GH_TOKEN }}

- name: Install pnpm package manager
uses: pnpm/action-setup@v4

- name: Set up Node.js version
uses: actions/setup-node@v4
with:
node-version-file: .nvmrc
cache: pnpm

- name: "Continuous Deployment: install"
run: |
pnpm install --frozen-lockfile
pnpm ls --recursive
- name: "Continuous Deployment: build"
run: pnpm run build

# lets exclude this for now...
# - name: "Continuous Deployment: publish to GitHub repository"
# env:
# GITHUB_TOKEN: ${{ secrets.GH_TOKEN }}
# GIT_AUTHOR_EMAIL: ""
# GIT_AUTHOR_NAME: "NL Design System"
# GIT_COMMITTER_EMAIL: ""
# GIT_COMMITTER_NAME: "NL Design System"
# run: |
# git push --set-upstream origin HEAD
# pnpm run release

- name: "Continuous Deployment: publish to npm"
env:
NPM_TOKEN: ${{ secrets.NPM_TOKEN }}
run: |
pnpm config set "//registry.npmjs.org/:_authToken" "${NPM_TOKEN}"
pnpm run publish
pnpm config delete "//registry.npmjs.org/:_authToken"
# publish-website:
# runs-on: ubuntu-latest
# needs: build
# if: github.ref == 'refs/heads/main'
#
# environment:
# name: github-pages
# url: ${{ steps.deploy-pages.outputs.page_url }}
#
# permissions:
# pages: write
# id-token: write
#
# steps:
# - name: Deploy to GitHub Pages
# id: deploy-pages
# uses: actions/deploy-pages@v4

# publish-npm:
# runs-on: ubuntu-latest
# needs: [lint, test]
# if: github.ref == 'refs/heads/main'
#
# steps:
# - name: Checkout release branch
# uses: actions/checkout@v4
# with:
# token: ${{ secrets.GH_TOKEN }}
#
# - name: Install pnpm package manager
# uses: pnpm/action-setup@v4
#
# - name: Set up Node.js version
# uses: actions/setup-node@v4
# with:
# node-version-file: .nvmrc
# cache: pnpm
#
# - name: "Continuous Deployment: install"
# run: |
# pnpm install --frozen-lockfile
# pnpm ls --recursive
#
# - name: "Continuous Deployment: build"
# run: pnpm run build

# lets exclude this for now...
# - name: "Continuous Deployment: publish to GitHub repository"
# env:
# GITHUB_TOKEN: ${{ secrets.GH_TOKEN }}
# GIT_AUTHOR_EMAIL: ""
# GIT_AUTHOR_NAME: "NL Design System"
# GIT_COMMITTER_EMAIL: ""
# GIT_COMMITTER_NAME: "NL Design System"
# run: |
# git push --set-upstream origin HEAD
# pnpm run release

# - name: "Continuous Deployment: publish to npm"
# env:
# NPM_TOKEN: ${{ secrets.NPM_TOKEN }}
# run: |
# pnpm config set "//registry.npmjs.org/:_authToken" "${NPM_TOKEN}"
# pnpm run publish
# pnpm config delete "//registry.npmjs.org/:_authToken"
2 changes: 0 additions & 2 deletions proprietary/design-tokens/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -18,8 +18,6 @@
},
"scripts": {
"clean": "rimraf dist/",
"build": "npm-run-all clean build:**",
"build:style-dictionary": "style-dictionary build --config ./style-dictionary.config.json",
"watch": "npm-run-all watch:**",
"watch:style-dictionary": "chokidar --follow-symlinks --initial --command 'pnpm run build' 'src/**/*.tokens.json'"
},
Expand Down

0 comments on commit 804e523

Please sign in to comment.