https://github.com/solidlabresearch/solid-menubar-app
https://github.com/solidlabresearch/solid-menubar-app
Last synced: 2 months ago
JSON representation
- Host: GitHub
- URL: https://github.com/solidlabresearch/solid-menubar-app
- Owner: SolidLabResearch
- Created: 2023-01-02T10:48:06.000Z (about 3 years ago)
- Default Branch: main
- Last Pushed: 2023-05-16T05:10:23.000Z (almost 3 years ago)
- Last Synced: 2025-01-17T07:09:34.493Z (about 1 year ago)
- Language: JavaScript
- Size: 483 KB
- Stars: 2
- Watchers: 1
- Forks: 0
- Open Issues: 4
-
Metadata Files:
- Readme: README.md
Awesome Lists containing this project
README
# Solid menubar app example
## Important
- I didn't clean this code or add any in-line documentation.
- The authentication works only with the
[Community Solid Server](https://github.com/CommunitySolidServer/CommunitySolidServer) (CSS) as identity provider,
because the app relies on CSS'
[Client Credentials](https://communitysolidserver.github.io/CommunitySolidServer/6.x/usage/client-credentials/).
The data can be stored on any Solid pod though.
There is [this issue](https://github.com/SolidLabResearch/solid-menubar-app/issues/6)
to find out how the app can work with Solid-OIDC.
## Usage
1. Install dependencies via
```shell
npm i
```
2. Copy config.example.json to config.json via
```shell
cp config.example.json config.json
```
3. Edit config.json. See details below.
4. Start app via
```shell
npm start
```
## Config file
The config file supports the following attributes:
- `webid`: your WebID
- `email`: email to log in to your pod/identity provider
- `password`: password to log in to your pod/identity provider
- `serverUrl`: url of your identify provider
- `icon`: path of the icon to show in the menubar
- `vacations`: array of vacation calendars with the properties `vacationUrl` and `webid`
- `vacations[*].vacationUrl`: url of a vacation calendar
- `vacations[*].webid`: WebID to whom the vacation calendar belongs
You find an example config file in `config.examnple.json`.
## Create playground pods and add calendars
You can create three pods for testing by doing the following steps:
1. Navigate to `pod-example-data` via `cd pod-example-data`.
2. Execute the script `create-example-pods.js` via `node create-example-pods.js`.
The details of the pods are
| Email | Password | Identity provider | WebID | Calendar |
|----------------|----------|-------------------------------------|-------------------------------------------------------|-----------------------------------------------------------------|
| c1@example.com | `test` | https://pod.playground.solidlab.be/ | https://pod.playground.solidlab.be/c1/profile/card#me | https://pod.playground.solidlab.be/c1/profile/vacation-calendar |
| c2@example.com | `test` | https://pod.playground.solidlab.be/ | https://pod.playground.solidlab.be/c2/profile/card#me | https://pod.playground.solidlab.be/c2/profile/vacation-calendar |
| c3@example.com | `test` | https://pod.playground.solidlab.be/ | https://pod.playground.solidlab.be/c3/profile/card#me | None |
You use `c3@example.com` as your account for logging in with the app.
This account is already configured in `pod-example-data/config.json`.
## Screenshot

## Screencast
You find a screencast of the app [here](https://cloud.ilabt.imec.be/index.php/s/HEeGsCS4PiQxaS7).
## Launch a startup (macOS)
Follow these steps to launch the app a startup in macOS:
1. Copy `be.ugent.vacation.example.plist` to `~/Library/LaunchAgents/be.ugent.vacation.plist`.
2. Update paths to this directory in `~/Library/LaunchAgents/be.ugent.vacation.plist`.
3. Copy `run-launch.example.sh` to `run-launch.sh`.
4. Update the `PATH` variable in `run-launch.sh`.
5. Load app via `launchctl load be.ugent.vacation.plist`.