go get github.com/gorilla/mux
go get -u golang.org/x/text/cmd/gotext
go get -u github.com/procyon-projects/chrono
git clone https://github.com/leblanc-simon/open-go-paste
cd open-go-paste/server
go run *.go
First, build binary :
cd open-go-paste/server
go build -o open-go-server *.go
Then, launch server :
./open-go-server
The server will be launched at http://127.0.0.1:8080
and the datas directory will be ../datas
relative to the current working drectory.
All options are managed by environment variables.
- Customize listen IP :
OPEN_GO_PASTE_SERVER=0.0.0.0
- Customize listen port :
OPEN_GO_PASTE_PORT=3000
- Customize datas directory :
OPEN_GO_PASTE_DATAS_FOLDER=/var/open-go-paste/datas
- Customize CSS :
OPEN_GO_PASTE_CUSTOM_CSS="/static/css/custom.css"
- Customize clean datas CRON :
OPEN_GO_PASTE_CRON="0 0 0 * * *"
(CRON syntax with seconds)
In template, we use the function trans
. To extract string, use release/extract-message-from-template.sh
- https://highlightjs.org/
- https://github.com/showdownjs/showdown
- https://ionicons.com/ (Copy and mail icons are licensed under MIT)
- Simon Leblanc [email protected] (Code and design)
- Lucie Lenfant (Logos)