This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| $ /etc/logrotate.d/ghost: | |
| /var/www/ghost/content/logs/*.log { | |
| weekly | |
| rotate 12 | |
| compress | |
| copytruncate | |
| } | |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| package main | |
| import ( | |
| "fmt" | |
| "golang.org/x/text/language" | |
| "golang.org/x/text/message" | |
| ) | |
| func germanNumber(n float64) string { | |
| p := message.NewPrinter(language.German) |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| plugins { | |
| id("com.cosminpolifronie.gradle.plantuml") version "1.6.0" | |
| } | |
| // ... | |
| configure<com.cosminpolifronie.gradle.plantuml.PlantUmlPluginExtension> { | |
| receivedRenders.add( | |
| com.cosminpolifronie.gradle.plantuml.PlantUmlReceivedRender( |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| // guessNameFromMail - Examples: | |
| // [email protected] -> Warren Buffett | |
| // [email protected] -> Warren Buffett | |
| // [email protected] -> Warren Buffett | |
| // [email protected] -> W. Buffett | |
| func guessNameFromMail(mail string) (firstname, lastname string) { | |
| re := regexp.MustCompile(`^([A-Za-z]+)[\-\.\_]([A-Za-z]+)[0-9]*@`) | |
| matches := re.FindAllStringSubmatch(mail, -1) | |
| if len(matches) == 1 && len(matches[0]) == 3 { | |
| firstname := strings.Title(matches[0][1]) |