Skip to content

Commit 29581c2

Browse files
authored
Add setup-pollapo docs (#2)
1 parent f19cd8c commit 29581c2

File tree

1 file changed

+35
-0
lines changed

1 file changed

+35
-0
lines changed
Lines changed: 35 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,35 @@
1+
## Login first
2+
3+
After installing the `pollapo` cli, you have to login to the Github using `pollapo`.
4+
`pollapo` installs your protobuf packages from Github repository.
5+
6+
```bash
7+
pollapo login
8+
```
9+
10+
## Install protobuf dependency
11+
12+
For add dependency, you have to just `pollapo add <package-name>@<version|branch|commit>` and say yes to the `pollapo` cli to create new `pollapo.yml` file. Here is an example:
13+
```bash
14+
pollapo add pbkit/interface-pingpong-server@main
15+
```
16+
17+
Now you can see the `pollapo.yml` file in your project root.
18+
19+
```yaml
20+
deps:
21+
- pbkit/interface-pingpong-server@main
22+
root:
23+
lock:
24+
pbkit/interface-pingpong-server@main: 58425678c6284305dd09130075cecb54a3a3d32c
25+
```
26+
The dependency infos and the lock hash of the packages will be printed in `pollapo.yml`.
27+
(The hash can be different!) This will resolve the version issue of the packages when you re-install deps with branch name.
28+
29+
## Installed protobuf packages
30+
31+
Use `pollapo install` to re-install your all deps. You can find installed protobuf packages in `.pollapo` directory.
32+
33+
If you want to update your lock version of dependency, just remove the lock line and re-install with `pollapo install`.
34+
35+
Perfect! Now you can use `pb` cli to compile the protobuf schema.

0 commit comments

Comments
 (0)