diff --git a/.github/workflows/tests.yml b/.github/workflows/tests.yml index f70f44e..e45d6c6 100644 --- a/.github/workflows/tests.yml +++ b/.github/workflows/tests.yml @@ -13,7 +13,10 @@ jobs: node-version: '16.x' cache: 'npm' - name: Install dependencies - run: npm ci + run: | + npm config set '@fortawesome:registry=https://npm.fontawesome.com/' + npm config set '//npm.fontawesome.com/:_authToken' "${{ secrets.FONTAWESOME_TOKEN }}" + npm ci - name: Create test build run: npm run test-build - name: Cache test build diff --git a/.gitignore b/.gitignore index 6c00843..d815ffd 100644 --- a/.gitignore +++ b/.gitignore @@ -1,5 +1,6 @@ .DS_Store dist node_modules +.npmrc .parcel-cache ui-assets diff --git a/README.md b/README.md index fa15ca2..3645561 100644 --- a/README.md +++ b/README.md @@ -6,9 +6,13 @@ View at: https://cdlib.github.io/cdlib-ui ## Installation -Requires Node, npm. +Requires Node, npm and Font Awesome Pro token -Run `npm install`. +1. Add the Font Awesome Pro token as a [GitHub Actions secret](https://github.com/Azure/actions-workflow-samples/blob/master/assets/create-secrets-for-GitHub-workflows.md) named `FONTAWESOME_TOKEN`. + +2. Add a **.npmrc** file within the project root using the [Per-Project](https://fontawesome.com/v5/docs/web/setup/use-package-managers#per-project) settings for Font Awesome Pro, including your token. This file is automatically ignored by Git and should not be committed. + +3. Run `npm install`. ## Developing diff --git a/package-lock.json b/package-lock.json index 0eab26b..0bef92d 100644 --- a/package-lock.json +++ b/package-lock.json @@ -13,6 +13,7 @@ }, "devDependencies": { "@faker-js/faker": "^7.6.0", + "@fortawesome/fontawesome-pro": "^6.2.1", "@frctl/fractal": "^1.5.13", "@frctl/mandelbrot": "^1.4.0", "@parcel/optimizer-data-url": "^2.8.0", @@ -272,6 +273,15 @@ "npm": ">=6.0.0" } }, + "node_modules/@fortawesome/fontawesome-pro": { + "version": "6.2.1", + "resolved": "https://npm.fontawesome.com/@fortawesome/fontawesome-pro/-/6.2.1/fontawesome-pro-6.2.1.tgz", + "integrity": "sha512-dHk7iiCf5MCmoUvmrYzfN/I3gebpgpA1oqlOffgOThnsaAR4kpaQ5YMTdkdG99Of1hnN0Bok6R+HE28zXb3SOg==", + "dev": true, + "engines": { + "node": ">=6" + } + }, "node_modules/@frctl/core": { "version": "0.3.4", "resolved": "https://registry.npmjs.org/@frctl/core/-/core-0.3.4.tgz", @@ -17357,6 +17367,12 @@ "integrity": "sha512-XK6BTq1NDMo9Xqw/YkYyGjSsg44fbNwYRx7QK2CuoQgyy+f1rrTDHoExVM5PsyXCtfl2vs2vVJ0MN0yN6LppRw==", "dev": true }, + "@fortawesome/fontawesome-pro": { + "version": "6.2.1", + "resolved": "https://npm.fontawesome.com/@fortawesome/fontawesome-pro/-/6.2.1/fontawesome-pro-6.2.1.tgz", + "integrity": "sha512-dHk7iiCf5MCmoUvmrYzfN/I3gebpgpA1oqlOffgOThnsaAR4kpaQ5YMTdkdG99Of1hnN0Bok6R+HE28zXb3SOg==", + "dev": true + }, "@frctl/core": { "version": "0.3.4", "resolved": "https://registry.npmjs.org/@frctl/core/-/core-0.3.4.tgz", diff --git a/package.json b/package.json index fbac5fe..eda9ad9 100644 --- a/package.json +++ b/package.json @@ -43,6 +43,7 @@ "homepage": "https://github.com/cdlib/cdlib-ui#readme", "devDependencies": { "@faker-js/faker": "^7.6.0", + "@fortawesome/fontawesome-pro": "^6.2.1", "@frctl/fractal": "^1.5.13", "@frctl/mandelbrot": "^1.4.0", "@parcel/optimizer-data-url": "^2.8.0",