update
This commit is contained in:
70
README.md
70
README.md
@@ -125,8 +125,40 @@ For an enhanced tactile experience, Nexus Timer supports Smart Buttons based on
|
||||
"theme": "dark"
|
||||
}
|
||||
```
|
||||
## Developer Setup
|
||||
### Clone the repository
|
||||
```bash
|
||||
git clone https://gitea.virtonline.eu/2HoursProject/nexus-timer.git
|
||||
cd nexus-timer
|
||||
```
|
||||
Run the live update server locally
|
||||
```bash
|
||||
npm run dev
|
||||
```
|
||||
### Modify the app
|
||||
Make code changes...
|
||||
### Test the PWA locally
|
||||
Open it in your browser:
|
||||
[http://localhost:8080/](http://localhost:8080/)
|
||||
### Git Pre-Commit Hook
|
||||
This project uses a Git pre-commit hook to automatically updates the build timestamp placeholder in `src/views/InfoView.vue` and increments the `CACHE_VERSION` in `public/service-worker.js` (it is the indicator for the installed PWA that the new version is available). This ensures that each commit intended for a build/deployment reflects the correct information.
|
||||
|
||||
#### Configure Git to use the local hooks directory
|
||||
Tell the Git to use the hooks located in the `.githooks` directory:
|
||||
```bash
|
||||
git config core.hooksPath .githooks
|
||||
```
|
||||
This step needs to be done once per local clone of the repository. The script `scripts/git-hooks/pre-commit.cjs` will be executed before every commit.
|
||||
### Commit & Push
|
||||
Stage changes, commit and push
|
||||
```bash
|
||||
git add .
|
||||
git commit -m 'fixed visuals'
|
||||
git push
|
||||
```
|
||||
## Building for the production
|
||||
Navigate to the projects' directory on the server
|
||||
### On the Server
|
||||
Navigate to the service directory on the server
|
||||
```bash
|
||||
cd /virt
|
||||
```
|
||||
@@ -177,40 +209,8 @@ curl https://nexus-timer.virtonline.eu
|
||||
Or open it in your browser:
|
||||
[https://nexus-timer.virtonline.eu](https://nexus-timer.virtonline.eu)
|
||||
|
||||
## Developer Setup
|
||||
|
||||
### Clone the repository
|
||||
```bash
|
||||
git clone https://gitea.virtonline.eu/2HoursProject/nexus-timer.git
|
||||
cd nexus-timer
|
||||
```
|
||||
### Git Pre-Commit Hook
|
||||
This project uses a Git pre-commit hook to automatically updates the build timestamp placeholder in `src/views/InfoView.vue` and increments the `CACHE_VERSION` in `public/service-worker.js` (it is the indicator for the installed PWA that the new version is available). This ensures that each commit intended for a build/deployment reflects the correct information.
|
||||
|
||||
#### Configure Git to use the local hooks directory
|
||||
After cloning the repository, run the following command in your terminal from the project root to tell Git to use the hooks located in the `.githooks` directory:
|
||||
```bash
|
||||
git config core.hooksPath .githooks
|
||||
```
|
||||
This step needs to be done once per local clone of the repository. The script `scripts/git-hooks/pre-commit.cjs` will be executed before every commit.
|
||||
### Modify the app
|
||||
Make code changes...
|
||||
|
||||
Run the live update server locally
|
||||
```bash
|
||||
npm run dev
|
||||
```
|
||||
#### Test the PWA locally
|
||||
Open it in your browser:
|
||||
[http://localhost:8080/](http://localhost:8080/)
|
||||
|
||||
Stage changes, commit and push
|
||||
```bash
|
||||
git add .
|
||||
git commit -m 'fixed visuals'
|
||||
git push
|
||||
```
|
||||
### Release the update
|
||||
## Release the update
|
||||
### On the Server
|
||||
Navigate to the app directory on your server
|
||||
```bash
|
||||
cd /virt/nexus-timer
|
||||
|
||||
Reference in New Issue
Block a user