Skip to content

Commit

Permalink
fix: use strictly unix commands for clear-styles
Browse files Browse the repository at this point in the history
  • Loading branch information
logonoff committed Jan 14, 2025
1 parent fdf5ffc commit f57b6db
Show file tree
Hide file tree
Showing 2 changed files with 8 additions and 6 deletions.
10 changes: 6 additions & 4 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -6,9 +6,11 @@ View the templates at https://openshift.github.io/oauth-templates/.

## Development

1. Install [Jekyll](https://jekyllrb.com/docs/installation/).
1. Run `bundle install`.
1. Run `bundle exec jekyll serve`.
1. Install [Jekyll](https://jekyllrb.com/docs/installation/) and run `bundle install`.
1. Install [Yarn](https://yarnpkg.com/lang/en/docs/install) and run `yarn install`.
- Note that certain dependencies require Node.js 20+. You can install [n](https://www.npmjs.com/package/n) to switch between node versions.
1. Run `yarn serve-jekyll`
- Note that `yarn generate-styles` will have to be run if there are new PatternFly classes added to the HTML.

### Updating PatternFly

Expand All @@ -17,7 +19,7 @@ Github Pages only runs in safe mode, preventing the usage of [symlinks](https://
1. Install [Jekyll](https://jekyllrb.com/docs/installation/) and run `bundle install`.
1. Install [Yarn](https://yarnpkg.com/lang/en/docs/install) and run `yarn install`.
1. Run `yarn upgrade @patternfly/patternfly`.
1. Run `yarn generate-styles`
1. Run `yarn generate-styles`.
1. Verify there are no regressions by running `yarn serve-jekyll`. Note that the CSS will not be automatically updated, so if you make changes to the HTML, you will need to run `yarn generate-styles` again.
1. Commit the changes.

Expand Down
4 changes: 2 additions & 2 deletions package.json
Original file line number Diff line number Diff line change
Expand Up @@ -7,10 +7,10 @@
"license": "Apache-2.0",
"scripts": {
"build-jekyll": "rm -rf _site && bundle exec jekyll build",
"clear-styles": "pushd ./_includes/styles && echo -n | tee errors.css index.css login.css providers.css",
"clear-styles": "cd ./_includes/styles && rm -f *.css && touch errors.css index.css login.css providers.css",
"generate-styles": "yarn clear-styles && yarn build-jekyll && node generate-styles.mjs",
"rebuild": "yarn generate-styles && yarn build-jekyll",
"serve-jekyll": "bundle exec jekyll serve",
"serve-jekyll": "yarn generate-styles && bundle exec jekyll serve",
"generate-branding-secret": "yarn rebuild && rm -f branding-secret.yaml && node generate-branding-secret.mjs rho"
},
"devDependencies": {
Expand Down

0 comments on commit f57b6db

Please sign in to comment.