Skip to content

Commit

Permalink
Merge branch 'release/0.2.9'
Browse files Browse the repository at this point in the history
  • Loading branch information
giper45 committed Oct 6, 2023
2 parents aaa647f + cf7c509 commit 22305cf
Show file tree
Hide file tree
Showing 3 changed files with 295 additions and 14 deletions.
18 changes: 9 additions & 9 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -52,16 +52,16 @@ And using the following packages:
## Add a tool
A tool is composed by:
- A markdown file in the */tools* folder
- An entry into a Javascript file (in */webapp/src/config/tools.ts*)
- An entry into a Javascript file (in */web/src/config/tools.ts*)

We want people to contribute, so we created a script to automate the process of adding a new tool. All you have to do is add the **description** and (optionally) the **cheatsheet**. The command is ``bootstrap``, here is an example:
<p align="center">
<img src="docs/bootstrap.gif">
</p>

To use the ``boostrap`` command you have to:
- ``yarn install`` in the main directory
- ``yarn run bootstrap`` in the main directory
- ``pnpm install`` in the `web` folder
- ``pnpm run bootstrap`` in the `web` folder
- Add the mandatory informations to add a new tool

The mandatory informations are the following:
Expand All @@ -75,29 +75,29 @@ The last thing you have to do is to add the **description** and (optionally) the
## Development
This section provides a set of commands to run the application locally.

PLEASE use **yarn** over **npm**
PLEASE use **pnpm** over **npm**

### Setup
This is a **React** based application. Before running it you have to install all the needed packages with the following command:
```
yarn install && cd ./webapp && yarn install
cd ./web && pnpm install
```

### Build
To build the app you have to run:
```
yarn run build
pnpm run build
```

### Run
To execute the app locally you have to run:
```
yarn start
pnpm dev
```

Please note that the folder used for showing the Markdown files in the React application is **not** the */tools* folder, but a directory inside the source code of the React app itself (*/webapp/src/_tools*). Every time you run ``yarn start`` from the main directory the */tools* folder is copied in */webapp/src/_tools*. So if you add a new tool while the app is running it won't show up until you update the */webapp/src/_tools* folder. For this reason a command has been added to ease this work, you can easily copy the */tools* folder by running the following command while in the main directory:
Please note that the folder used for showing the Markdown files in the React application is **not** the */tools* folder, but a directory inside the source code of the React app itself (*/web/src/_tools*). Every time you run ``yarn start`` from the main directory the */tools* folder is copied in */web/src/_tools*. So if you add a new tool while the app is running it won't show up until you update the */web/src/_tools* folder. For this reason a command has been added to ease this work, you can easily copy the */tools* folder by running the following command while in the main directory:
```
yarn run update
pnpm run update
```


Expand Down
11 changes: 6 additions & 5 deletions web/package.json
Original file line number Diff line number Diff line change
@@ -1,16 +1,16 @@
{
"name": "houdini-web",
"license": "GPL-3.0",
"version": "0.2.8",
"version": "0.2.9",
"type": "module",
"scripts": {
"prepare": "cd .. && husky install web/.husky",
"fetch-library": "npx ts-node --esm scripts/fetch_library.ts",
"fetch-library": "tsx scripts/fetch_library.ts",
"copy-library": "copyfiles -u 2 ../library/**/* src/library/",
"generate-tools-list": "npx ts-node --esm scripts/generate_tools_list.ts",
"generate-tools-list": "tsx scripts/generate_tools_list.ts",
"postinstall": "pnpm copy-library && pnpm generate-tools-list",
"check": "npx ts-node --esm scripts/check.ts",
"build-sitemap": "npx ts-node --esm scripts/sitemap-builder.ts",
"check": "tsx scripts/check.ts",
"build-sitemap": "tsx scripts/sitemap-builder.ts",
"dev": "pnpm check && vite",
"build": "pnpm check && tsc && vite build && pnpm build-sitemap",
"lint": "eslint src",
Expand Down Expand Up @@ -57,6 +57,7 @@
"prettier": "^2.8.8",
"tailwindcss": "^3.3.1",
"ts-node": "^10.9.1",
"tsx": "^3.13.0",
"typescript": "^5.0.2",
"vite": "^4.3.0",
"vite-plugin-dynamic-import": "^1.2.7"
Expand Down
Loading

0 comments on commit 22305cf

Please sign in to comment.