Skip to content

Added alternative installation instruction #13

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Open
wants to merge 2 commits into
base: master
Choose a base branch
from
Open
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
28 changes: 28 additions & 0 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -10,6 +10,8 @@ Build/Runs your crystal application, watches files, and rebuilds/reruns app on f

## Installation

### Installation using ruby script
Copy link
Owner

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I'd opt to rename this from Installation using ruby script to Quick Installation.

Copy link
Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

@samueleaton Please change if needed, as English is not my native language, I might use some cumbersome words to describe things.


To install in your project, from the root directory of your project, run:
```bash
curl -fsSLo- https://raw.githubusercontent.com/samueleaton/sentry/master/install.rb | ruby
Expand All @@ -23,6 +25,32 @@ This will install the Sentry CLI tool. To use the Crystal API, see [CRYSTAL_API.

**Troubleshooting the install:** This ruby install script is just a convenience. If it does not work, simply: (1) place the files located in the `src` dir into a your project in a `dev/` dir, and (2) compile sentry by doing `crystal build --release dev/sentry_cli.cr -o ./sentry`.


### Installation using shard.yml and Makefile

Add Sentry to your `shard.yml`'s `development_dependencies` section:

```yml
development_dependencies:
sentry:
github: samueleaton/sentry
```

And add following instructions to your `Makefile`:

```Makefile
sentry: ./lib/sentry/src/sentry_cli.cr
mkdir -p ./bin/
crystal build --release ./lib/sentry/src/sentry_cli.cr -o ./bin/sentry
@echo "Sentry is compiled to ./bin/sentry"
```

Install shards using command `$ shards install`, which downloads sentry under directory `./lib/sentry/`. And now you can compile sentry `$ make sentry`. It creates runnable binary `./bin/sentry` that can be used as following:

```bash
./bin/sentry [options]
```

## Usage

Assuming `sentry.cr` was correctly placed in `[your project name]/dev/sentry.cr` and compiled into the root of your app as `sentry`, simply run:
Expand Down