Skip to content
This repository has been archived by the owner on Aug 1, 2023. It is now read-only.

Commit

Permalink
update readme (#101)
Browse files Browse the repository at this point in the history
  • Loading branch information
mattnite authored Jun 18, 2021
1 parent 7ca5a18 commit 5bebf51
Showing 1 changed file with 30 additions and 24 deletions.
54 changes: 30 additions & 24 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -31,6 +31,7 @@ Table of contents
* [Update dependencies -- for package consumers](#update-dependencies----for-package-consumers)
* [Use gyro in Github Actions](#use-gyro-in-github-actions)
* [Publishing from an action](#publishing-from-an-action)
* [Completion Scripts](#completion-scripts)
* [Design philosophy](#design-philosophy)
* [Generated files](#generated-files)
* [gyro.zzz](#gyrozzz)
Expand Down Expand Up @@ -256,38 +257,30 @@ gyro remove iguanaTLS --from some_package

### Local development

Right now local development requires editing [gyro.zzz](#gyrozzz), there will be a cli
workflow in a future release.
One can switch out a dependency for a local copy using the `redirect`
subcommand. Let's say we're using `mattnite/tar` from astrolabe and we come
across a bug, we can debug with a local version of the package by running:

Let's say you have a dependency, `iguanaTLS`, and you have it cloned next to
your project. Your gyro.zzz will look something like this:

```yaml
deps:
alexnask/iguanaTLS: ^0.0.1
```
gyro redirect -a tar -p ../tar
```

You can comment out the package and replace it with a local one:
This will point gyro at your local copy, and when you're done you can revert the
redirect(s) with:

```yaml
deps:
#alexnask/iguanaTLS: ^0.0.1
iguanaTLS: src: local: "../iguanaTLS"
```
gyro redirect --clean
```

If the package had more than one exported package then you'd need to specify the
root file:
Multiple dependencies can be redirected. Build dependencies are redirected by
passing `-b`. You can even redirect the dependencies of a local package.

```yaml
deps:
#alexnask/iguanaTLS: ^0.0.1
iguanaTLS:
root: src/blarg.zig
src: local: "../iguanaTLS"
```
HOT tip: add this to your git `pre-commit` hook to catch you before accidentally
commiting redirects:

It is possible to go down the dependency tree further by doing this to the
`gyro.zzz` file in the local dependency.
```
gyro redirect --check
```

### Update dependencies -- for package consumers

Expand Down Expand Up @@ -336,6 +329,19 @@ jobs:
GYRO_ACCESS_TOKEN: ${{ secrets.GYRO_ACCESS_TOKEN }}
```
### Completion Scripts
Completion scripts can be generated by the `completion` subcommand, it is run
like so:

```
gyro completion -s <shell> <install path>
```

Right now only `zsh` is the only supported shell, and this will create a `_gyro`
file in the install path. If you are using `oh-my-zsh` then this path should be
`$HOME/.oh-my-zsh/completions`.

## Design philosophy

The two main obectives for gyro are providing a great user experience and
Expand Down

0 comments on commit 5bebf51

Please sign in to comment.