mirror of
https://github.com/semaphoreui/semaphore.git
synced 2024-11-23 20:35:24 +01:00
80538908a8
- fix ./make.sh watch - rename .jade -> .pug
1.6 KiB
1.6 KiB
Pull Requests
When creating a pull-request you should:
- Open an issue first: Confirm that the change or feature will be accepted
- gofmt and vet the code: Use
gofmt
,golint
,govet
andgoimports
to clean up your code. - Update api documentation: If your pull-request adding/modifying an API request, make sure you update the swagger documentation (
api-docs.yml
)
Installation in a development environment
- Install Go
- Install MySQL / MariaDB
- Install node.js
- Set up the gopath
mkdir -p $GOPATH/src/github.com/ansible-semaphore && cd $GOPATH/src/github.com/ansible-semaphore
- Clone semaphore (with submodules)
git clone --recursive git@github.com:ansible-semaphore/semaphore.git && cd semaphore
- Install dev dependencies
go get ./... github.com/cespare/reflex github.com/jteeuwen/go-bindata/...
npm install async
npm install -g nodemon pug-cli less
- Set up config, database & run migrations
cat <<EOT >> config.json
{
"mysql": {
"host": "127.0.0.1:3306",
"user": "root",
"pass": "",
"name": "semaphore"
},
"port": ":3000"
}
EOT
echo "create database semaphore;" | mysql -uroot -p
go run cli/main.go -config ./config.json -migrate
Now it's ready to start.. Run ./make.sh watch
- Watches js files in
public/js/*
and compiles into a bundle - Watches css files in
public/css/*
and compiles into css code - Watches pug files in
public/html/*
and compiles them into html - Watches go files and recompiles the binary
- Open localhost:3000