All Projects → samueleaton → Sentry

samueleaton / Sentry

Licence: mit
Build/Runs your crystal application, watches files, and rebuilds/restarts app on file changes

Programming Languages

crystal
512 projects

Labels

Projects that are alternatives of or similar to Sentry

Lunar
Intelligent adaptive brightness for your external monitors
Stars: ✭ 2,712 (+1034.73%)
Mutual labels:  monitor
Adi
ADI(Android Debug Intensive) 是通过 JVMTI 实现的 Android 应用开发调试的增强工具集,目前主要提供性能相关的监控能力。
Stars: ✭ 194 (-18.83%)
Mutual labels:  monitor
Cryptotrader
A cryptocurrency trader for all famous exchanges
Stars: ✭ 228 (-4.6%)
Mutual labels:  monitor
Antminer Monitor
Cryptocurrency ASIC mining hardware monitor using a simple web interface
Stars: ✭ 176 (-26.36%)
Mutual labels:  monitor
Ios Monitor Platform
📚 iOS 性能监控 SDK —— Wedjat(华狄特)开发过程的调研和整理
Stars: ✭ 2,316 (+869.04%)
Mutual labels:  monitor
Uptime Monitor App
A PHP application to monitor uptime and ssl certificates
Stars: ✭ 205 (-14.23%)
Mutual labels:  monitor
Gmonitor
gmonitor is a GPU monitor (Nvidia only at the moment)
Stars: ✭ 169 (-29.29%)
Mutual labels:  monitor
Centreon Plugins
Collection of standard plugins to discover and gather cloud-to-edge metrics and status across your whole IT infrastructure.
Stars: ✭ 234 (-2.09%)
Mutual labels:  monitor
Monitorfe
🍉前端埋点监控,提供前端 JS 执行错误,第三方资源加载异常,Ajax 请求错误监控
Stars: ✭ 190 (-20.5%)
Mutual labels:  monitor
Wam
Web App Monitor
Stars: ✭ 216 (-9.62%)
Mutual labels:  monitor
Myperf4j
High performance Java APM. Powered by ASM. Try it. Test it. If you feel its better, use it.
Stars: ✭ 2,281 (+854.39%)
Mutual labels:  monitor
Briarids
An All-In-One home intrusion detection system (IDS) solution for the Raspberry PI.
Stars: ✭ 187 (-21.76%)
Mutual labels:  monitor
Stonky
A command line dashboard for monitoring stocks
Stars: ✭ 208 (-12.97%)
Mutual labels:  monitor
Urlwatch
urlwatch monitors webpages for you
Stars: ✭ 2,294 (+859.83%)
Mutual labels:  monitor
Moreco
moreco 是一个能够为小、中、大型项目提供最合适架构的一条龙生态系统。满足项目从小型到中型至大型的衍变过程。从编码到监控至运维都满足、且各种功能都插件化,支持插件间的切换。支持Spring Boot、Spring Cloud、Axon 无缝升级
Stars: ✭ 231 (-3.35%)
Mutual labels:  monitor
Nevergreen
🐤 A build monitor with attitude
Stars: ✭ 170 (-28.87%)
Mutual labels:  monitor
Oknetworkmonitor
A network monitor for OkHttp.
Stars: ✭ 204 (-14.64%)
Mutual labels:  monitor
Simplegodotcrtshader
A simple Godot shader that simulates CRT Displays
Stars: ✭ 236 (-1.26%)
Mutual labels:  monitor
Droidtelescope
DroidTelescope(DT),Android端App性能监控框架
Stars: ✭ 231 (-3.35%)
Mutual labels:  monitor
Webmonitor
实时监控网页变化,并发送通知(Monitor web page changes in real time and send notifications)
Stars: ✭ 212 (-11.3%)
Mutual labels:  monitor

cubbie!


Sentry 🤖

Build/Runs your crystal application, watches files, and rebuilds/reruns app on file changes

Installation

To install in your project, from the root directory of your project, run:

curl -fsSLo- https://raw.githubusercontent.com/samueleaton/sentry/master/install.cr | crystal eval

If using Crystal version 0.24.2 try the following:

curl -fsSLo- https://raw.githubusercontent.com/samueleaton/sentry/crystal-v0.24.2/install.cr | crystal eval

If using Crystal version 0.23.1 or lower try the following:

curl -fsSLo- https://raw.githubusercontent.com/samueleaton/sentry/crystal-v0.23.1/install.cr | crystal eval

This will install the Sentry CLI tool. To use the Crystal API, see CRYSTAL_API.md.

sentry

Troubleshooting the install: This 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.

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:

./sentry [options]

Options

Show Help Menu

./sentry --help

Example

$ ./sentry -h

Usage: ./sentry [options]
     -n NAME, --name=NAME             Sets the display name of the app process (default name: <your_app_here>)
     -b COMMAND, --build=COMMAND      Overrides the default build command
     --build-args=ARGS                Specifies arguments for the build command
     --no-build                       Skips the build step
     -r COMMAND, --run=COMMAND        Overrides the default run command
     --run-args=ARGS                  Specifies arguments for the run command
     -w FILE, --watch=FILE            Overrides default files and appends to list of watched files
     -c FILE, --config=FILE           Specifies a file to load for automatic configuration (default: '.sentry.yml')
     --install                        Run 'shards install' once before running Sentry build and run commands
     --no-color                       Removes colorization from output
     -i, --info                       Shows the values for build/run commands, build/run args, and watched files
     -h, --help                       Show this help

Override Default Build Command

./sentry -b "crystal build --release ./src/my_app.cr"

The default build command is crystal build ./src/[app_name].cr. The release flag is omitted by default for faster compilation time while you are developing.

Override Default Run Command

./sentry -r "./my_app"

The default run command is ./[app_name].

Override Default Files to Watch

./sentry -w "./src/**/*.cr" -w "./lib/**/*.cr"

The default files being watched are ["./src/**/*.cr", "./src/**/*.ecr"].

By specifying files to watch, the default will be omitted. So if you want to watch all of the file in your src directory, you will need to specify that like in the above example.

Show Info Before Running

This shows the values for the build command, run command, and watched files.

./sentry -i

Example

$ ./sentry -i

🤖  Sentry configuration:
       display name:   my_app
       shard name:     my_app
       install shards: true
       info:           true
       build:          crystal build ./src/my_app.cr
       build_args:     []
       run:            ./my_app
       run_args:       []
       watch:          ["./src/**/*.cr", "./src/**/*.ecr"]
🤖  Your SentryBot is vigilant. beep-boop...
...
...

Setting Build or Run Arguments

If you prefer granularity, you can specify arguments to the build or run commands using the --build-args or --run-args flags followed by a string of arguments.

./sentry -r "crystal" --run-args "spec --debug"

Running shards install Before Starting

This is especially usefull when initiating Sentry from a Dockerfile or package.json file. It guarantees all the shards are installed before running.

./sentry --install

Reading Configurations from a File

Sentry will automatically read configurations from .sentry.yml if it exists. This can be changed with -c FILE or --config=FILE.

See the YAML.mapping definition in the Config class in the /src/sentry.cr file for valid file properties.

Removing Colorization

Sentry output is colorized by default. To remove colorization, pass the --no-color argument.

Example

./sentry --no-color

Sentry Crystal API

See CRYSTAL_API.md

Why?

(1) It is tiring to have to stop and restart an app on every change.

(2) Docker!

Stop and restarting your app is especially expensive (and annoying) when running the app in a docker container, where one would need to totally rebuild the docker image for every change.

Now, for development, simply run sentry in your docker container, and it will rebuild the app from the docker container on any changes, without rebuilding the docker image/container.

Contributing

  1. Fork it ( https://github.com/samueleaton/sentry/fork )
  2. Create your feature branch (git checkout -b feat-my-new-feature)
  3. Commit your changes (git commit -am 'Add some feature')
  4. Push to the branch (git push origin feat-my-new-feature)
  5. Create a new Pull Request

Contributors

Disclaimer

Sentry is intended for use in a development environment, where failure is safe and expected 😉.

Note that the project description data, including the texts, logos, images, and/or trademarks, for each open source project belongs to its rightful owner. If you wish to add or remove any projects, please contact us at [email protected].