Skip to content

Commit

Permalink
Add build script
Browse files Browse the repository at this point in the history
  • Loading branch information
travissouthard committed May 8, 2024
1 parent 7e499e0 commit efe8cc9
Show file tree
Hide file tree
Showing 2 changed files with 24 additions and 1 deletion.
14 changes: 13 additions & 1 deletion README.md
Original file line number Diff line number Diff line change
Expand Up @@ -14,4 +14,16 @@ The main page and static site projects within are made with:
- Javascript
- JQuery

For more of the tools and projects Travis has worked on visit [the portfolio](https://travissouthard.com/#projects).
For more of the tools and projects Travis has worked on visit [the portfolio](https://travissouthard.com/#projects).

## Scripts

In this projects there is a `scripts` folder with the following scripts:

| Script | Description |
| ------ | ----------- |
| buildPages.js | Generates HTML files from the `data.json` file in the `data` folder |
| generateRssXml.js | Generates a `rss.xml` file from the `data.json` in the `data` folder |
| build | Updates the `data.json` file from `data.js` and runs `buildpages.js` and then `generateRssXml.js |

The only one needed to be run manually is `build` with the command: `./scripts/build`
11 changes: 11 additions & 0 deletions scripts/build
Original file line number Diff line number Diff line change
@@ -0,0 +1,11 @@
#!/bin/bash

main() {
node data/data.js > data/data.json
node scripts/buildPages.js
node scripts/generateRssXml.js
}

if [[ "${BASH_SOURCE[0]}" == "${0}" ]]; then
main "$@"
fi

0 comments on commit efe8cc9

Please sign in to comment.