-
Notifications
You must be signed in to change notification settings - Fork 98
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Add MAINTAINING.md and deploy action script
- Loading branch information
Showing
2 changed files
with
59 additions
and
0 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,26 @@ | ||
name: create-yorkie-app-publish | ||
on: | ||
workflow_dispatch: | ||
push: | ||
branches: | ||
- main | ||
paths: | ||
- tools/create-yorkie-app/** | ||
jobs: | ||
build: | ||
runs-on: ubuntu-latest | ||
steps: | ||
- name: Checkout ποΈ | ||
uses: actions/checkout@v2 | ||
- name: Setup Node π§ | ||
uses: actions/setup-node@v2 | ||
with: | ||
node-version: '18' | ||
cache: 'npm' | ||
cache-dependency-path: package-lock.json | ||
registry-url: 'https://registry.npmjs.org' | ||
- run: npm install | ||
- run: cd tools/create-yorkie-app && npm run build | ||
- run: npm publish --provenance | ||
env: | ||
NODE_AUTH_TOKEN: ${{ secrets.NPM_TOKEN }} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,33 @@ | ||
# Maintaining create-yorkie-app | ||
|
||
This package is an automated tool to scaffold an example project that shows practical usage of yorkie-js-sdk. | ||
|
||
```bash | ||
. | ||
βββ MAINTAINING.md | ||
βββ README.md | ||
βββ frameworks.ts # abstract data object representing examples/ directory | ||
βββ index.ts # main script | ||
βββ package.json | ||
βββ tsconfig.json | ||
βββ webpack.config.js | ||
``` | ||
|
||
## Adding a New Example | ||
|
||
Add information about your new example in [frameworks.ts](https://github.com/yorkie-team/yorkie-js-sdk/blob/main/tools/create-yorkie-app/frameworks.ts). | ||
|
||
Choose or create an appropriate category (e.g. vanilla, react, nextjs, vue, ...) and add an object like below to variants array. | ||
|
||
```ts | ||
{ | ||
name: directory_name, | ||
display: displayed_name_in_prompt | ||
} | ||
``` | ||
|
||
## Publishing a New Version | ||
|
||
Update the version in [package.json](https://github.com/yorkie-team/yorkie-js-sdk/blob/main/tools/create-yorkie-app/package.json#L3). | ||
|
||
Publication will be done via [create-yorkie-app-publish.yml](https://github.com/yorkie-team/yorkie-js-sdk/blob/main/.github/workflows/create-yorkie-app-publish.yml) when changes are pushed into main branch. |