Monitoring changes in the source file and automatically compile and run (restart).

Overview

dogo

Build Status Coverage License

Monitoring changes in the source file and automatically compile and run (restart).

中文

Install

go get github.com/liudng/dogo

Create config

Here's a config file sample, save the file as dogo.json:

{
    "WorkingDir": "{GOPATH}/src/github.com/liudng/dogo/example",
    "SourceDir": [
        "{GOPATH}/src/github.com/liudng/dogo/example"
    ],
    "SourceExt": [".c", ".cpp", ".go", ".h"],
    "BuildCmd": "go build github.com/liudng/dogo/example",
    "RunCmd": "example.exe",
    "Decreasing": 1
}

WorkingDir: working directory, dogo will auto change to this directory.

SourceDir: the list of source directories.

SourceExt: monitoring file type.

BuildCmd: the command of build and compile.

RunCmd: the program (full) path.

Decreasing: Ignore the number of modifies, it's only start counting after build success. Now it's supported in linux and windows.

Start monitoring

type the command to start:

dogo

or, specify a config file with -c

dogo -c=/path/to/dogo.json

the path can contain {GOPATH}.

screen capture

windows screen

Issues
  • Deleting source file causes infinite error

    Deleting source file causes infinite error

    Hi, "dogo" is really simplifying my workflow, thank you guys for creating and maintaining this utility but one thing makes me sad sometimes.

    Let's say I have the following scenario:

    1. Create new file(let's say "test.go")
    2. Start "dogo"
    3. Remove file

    In result "dogo" will constantly log: stat %filepath%: no such file or directory and I need to restart in order to continue the auto build. I'm using the latest version on OS X El Capitan by the way.

    enhancement 
    opened by G07cha 3
  • Exlude directories option

    Exlude directories option

    Is it possible to exclude certain directories? We have a node_modules directory and a vendor directory and these have a lot of files. Even putting a file extension as .go doensn't do much help.

    enhancement 
    opened by pyrossh 2
  • use DelayTime instead of Decreasing

    use DelayTime instead of Decreasing

    I use sublime to edit my file. After I press ctr+s, sublime will format my file and save it again. dogo will get two modify events and trigger 2 build and run. (because my app is web, it will report port is used error) If dogo delay 0.5 second to build and run, there will be no such issue. Maybe we don't need decreasing but just increase DelayTime, then we will not ignore any change.

    opened by zhangpy 2
  • Runcmd is launched with wrong working dir

    Runcmd is launched with wrong working dir

    Executable file should have working dir set to filepath.dir("[runcmd command]"). Why exist both "WorkingDir" and "SourceDir" if they must have the same value? I use "go install" as build command and wouldn't want to switch to an arbitrary build. (apart from issue it'a very useful utility)

    opened by simobgl 1
  • Added support for ignored files and folders. See issue #17

    Added support for ignored files and folders. See issue #17

    Just added Ignored field to JSON configuration and the Dogo struct to deal with ignored folders and files under the ignored folders.

    If the resource being checked is a folder it is just skipped from adding to the Dogo.sourceDir. All subsequent files under that directory are also ignored.

    I think it would have been easier to use map[string]string for the Dogo.Ignored field to perform a 1:1 search but I think it's easier to write only an array of files/folders in the JSON file.

    opened by samacs 4
  • using with code generation causes looping behavior

    using with code generation causes looping behavior

    In my project, I am using a Makefile that causes code generation. The build command, thus results in new .go files being created/changed, which triggers dogo to restart the build process, and now it starts looping. I think listening for changes should be paused until the build commend process exits.

    opened by jvsteiner 0
Releases(1.0_beta2)
A tool to restart a Docker container with a newer version of the image

repull A tool to restart a Docker container with a newer version of an image used by the container Often you may need to pull a newer version of an im

Eugene 23 May 14, 2022
Binary program to restart unhealthy Docker containers

DeUnhealth Restart your unhealthy containers safely Features Restart unhealthy containers marked with deunhealth.restart.on.unhealthy=true label Recei

Quentin McGaw 46 Jun 9, 2022
A dead simple, no frills Go cross compile tool

Gox - Simple Go Cross Compilation Gox is a simple, no-frills tool for Go cross compilation that behaves a lot like standard go build. Gox will paralle

Mitchell Hashimoto 4.3k Jul 1, 2022
Quickly cross-compile your C code

WORK IN PROGRESS: Viceroy is a very early work in progress and is subject to breaking changes. It's also subject to not really working all that well y

Robert Fratto 9 Apr 6, 2022
rld is a tiny tool that runs a go program and watch changes on it.

RLD rld is a tiny tool that runs a go program and watch changes on it. rld was inspired by Nodemon Installation Clone the git repository and build: $

Francis Sunday 10 Jun 13, 2022
Watch and print changes in k8s

Watch kubernetes resources and print the delta in changes.

Darren Shepherd 30 May 18, 2022
Watch and react to changes in Kubernetes TLS Secrets

cert-watch Watch and react to change in Kubernetes TLS Secrets. What is cert-watch? Kubernetes has introduced a number of different ways to keep certi

null 8 Feb 4, 2022
🤖 DroneCI plugin to skip pipelines based on files changes

DroneCI Skip Pipeline ?? DroneCI plugin to skip pipelines based on files changes Motivations This DroneCI plugin enables you skip (or short-circuit) a

Josh Komoroske 2 Jun 5, 2022
Open Source runtime tool which help to detect malware code execution and run time mis-configuration change on a kubernetes cluster

Kube-Knark Project Trace your kubernetes runtime !! Kube-Knark is an open source tracer uses pcap & ebpf technology to perform runtime tracing on a de

Chen Keinan 30 May 21, 2022
Prestic - Lets you define and run restic commands from a YAML file

Pete's Restic Lets you define and run restic commands from a YAML file. Features

Pete Taylor 0 Jan 10, 2022
`runenv` create gcloud run deploy `--set-env-vars=` option and export shell environment from yaml file.

runenv runenv create gcloud run deploy --set-env-vars= option and export shell environment from yaml file. Motivation I want to manage Cloud Run envir

sonatard 0 Feb 10, 2022
An open-source, distributed, cloud-native CD (Continuous Delivery) product designed for developersAn open-source, distributed, cloud-native CD (Continuous Delivery) product designed for developers

Developer-oriented Continuous Delivery Product ⁣ English | 简体中文 Table of Contents Zadig Table of Contents What is Zadig Quick start How to use? How to

null 0 Oct 19, 2021
Web user interface and service agent for the monitoring and remote management of WinAFL.

WinAFL Pet WinAFL Pet is a web user interface dedicated to WinAFL remote management via an agent running as a system service on fuzzing machines. The

Gabor Seljan 50 Jun 16, 2022
A tool for visualization and monitoring Redis cluster realtime

Redat is a tool for visualize Redis-cluster on terminal Features: Visualize master-replicas relations in the Redis cluster Monitor with metrics: memor

Alex Nguyen 6 Nov 15, 2021
Ansible-driven CI/CD and monitoring system

Ansible Semaphore Follow Semaphore on Twitter (AnsibleSem) and StackShare (ansible-semaphore). Ansible Semaphore is a modern UI for Ansible. It lets y

Ansiphore 0 Nov 15, 2021
Kstone is an etcd management platform, providing cluster management, monitoring, backup, inspection, data migration, visual viewing of etcd data, and intelligent diagnosis.

Kstone 中文 Kstone is an etcd management platform, providing cluster management, monitoring, backup, inspection, data migration, visual viewing of etcd

TKEStack 544 Jun 27, 2022
Metrics go: CudgX indicator management tool, which integrates monitoring and data analysis indicator capabilities

Metrics-Go metrics-go 是cudgx指标打点工具,它集成了监控和数据分析指标能力。 数据流程 指标数据流程为: 用户代码调用打点 SDK指标

Galaxy-Future 10 Mar 1, 2022
IT Asset Fleet Remote Management and Monitoring (RMM) platform

ratd Remote Access Toolkit Daemon IT Asset Remote Management and Monitoring (RMM) platform How to use: You can't, just yet. Release Plan Release 0 Cre

null 7 May 27, 2022
A K8s ClusterIP HTTP monitoring library based on eBPF

Owlk8s Seamless RED monitoring of k8s ClusterIP HTTP services. This library provides RED (rate,error,duration) monitoring for all(by default but exclu

null 17 Jun 16, 2022