Skip to content

Commit

Permalink
Rename gibo-go to gibo
Browse files Browse the repository at this point in the history
  • Loading branch information
simonwhitaker committed Jul 30, 2023
1 parent 717c874 commit 597ab86
Show file tree
Hide file tree
Showing 16 changed files with 47 additions and 48 deletions.
1 change: 0 additions & 1 deletion .gitignore
Original file line number Diff line number Diff line change
@@ -1,4 +1,3 @@
gibo

dist/
gibo-go
22 changes: 11 additions & 11 deletions .goreleaser.windows.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -14,7 +14,7 @@ builds:
- windows
ldflags:
# Default: '-s -w -X main.version={{.Version}} -X main.commit={{.Commit}} -X main.date={{.Date}} -X main.builtBy=goreleaser'
"-s -w -X github.com/simonwhitaker/gibo-go/cmd.version={{.Version}} -X github.com/simonwhitaker/gibo-go/cmd.commit={{.Commit}} -X github.com/simonwhitaker/gibo-go/cmd.date={{.Date}}"
"-s -w -X github.com/simonwhitaker/gibo/cmd.version={{.Version}} -X github.com/simonwhitaker/gibo/cmd.commit={{.Commit}} -X github.com/simonwhitaker/gibo/cmd.date={{.Date}}"

archives:
- format: zip
Expand All @@ -28,20 +28,20 @@ archives:
{{- if .Arm }}v{{ .Arm }}{{ end }}
chocolateys:
- name: gibo-go
title: "gibo-go: Fast access to .gitignore boilerplates"
project_source_url: https://github.com/simonwhitaker/gibo-go
package_source_url: https://github.com/simonwhitaker/gibo-go
project_url: https://github.com/simonwhitaker/gibo-go
release_notes: "https://github.com/simonwhitaker/gibo-go/releases/tag/v{{ .Version }}"
- name: gibo
title: "gibo: Fast access to .gitignore boilerplates"
project_source_url: https://github.com/simonwhitaker/gibo
package_source_url: https://github.com/simonwhitaker/gibo
project_url: https://github.com/simonwhitaker/gibo
release_notes: "https://github.com/simonwhitaker/gibo/releases/tag/v{{ .Version }}"
api_key: "{{ .Env.CHOCOLATEY_API_KEY }}"
docs_url: https://github.com/simonwhitaker/gibo-go/blob/main/README.md
license_url: https://github.com/simonwhitaker/gibo-go/blob/main/LICENSE
docs_url: https://github.com/simonwhitaker/gibo/blob/main/README.md
license_url: https://github.com/simonwhitaker/gibo/blob/main/LICENSE
require_license_acceptance: false
url_template: "https://github.com/simonwhitaker/gibo-go/releases/download/{{ .Tag }}/{{ .ArtifactName }}"
url_template: "https://github.com/simonwhitaker/gibo/releases/download/{{ .Tag }}/{{ .ArtifactName }}"
authors: Simon Whitaker
description: |-
**gibo-go** (short for .gitignore boilerplates in Go) is a command-line tool to help you easily access .gitignore boilerplates from [github.com/github/gitignore](https://github.com/github/gitignore).
**gibo** (short for .gitignore boilerplates in Go) is a command-line tool to help you easily access .gitignore boilerplates from [github.com/github/gitignore](https://github.com/github/gitignore).
It is a reimplementation of [gibo](https://github.com/simonwhitaker/gibo), in Go.
tags: git gitignore
Expand Down
6 changes: 3 additions & 3 deletions .goreleaser.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -16,7 +16,7 @@ builds:
- darwin
ldflags:
# Default: '-s -w -X main.version={{.Version}} -X main.commit={{.Commit}} -X main.date={{.Date}} -X main.builtBy=goreleaser'
"-s -w -X github.com/simonwhitaker/gibo-go/cmd.version={{.Version}} -X github.com/simonwhitaker/gibo-go/cmd.commit={{.Commit}} -X github.com/simonwhitaker/gibo-go/cmd.date={{.Date}}"
"-s -w -X github.com/simonwhitaker/gibo/cmd.version={{.Version}} -X github.com/simonwhitaker/gibo/cmd.commit={{.Commit}} -X github.com/simonwhitaker/gibo/cmd.date={{.Date}}"

archives:
- format: tar.gz
Expand All @@ -33,8 +33,8 @@ archives:
- goos: windows
format: zip
brews:
- name: gibo-go
homepage: https://github.com/simonwhitaker/gibo-go
- name: gibo
homepage: https://github.com/simonwhitaker/gibo
repository:
owner: simonwhitaker
name: homebrew-tap
Expand Down
8 changes: 4 additions & 4 deletions Dockerfile
Original file line number Diff line number Diff line change
Expand Up @@ -8,13 +8,13 @@ COPY go.mod go.sum ./
RUN go mod download

COPY . ./
RUN CGO_ENABLED=0 GOOS=linux go build -o /gibo-go
RUN CGO_ENABLED=0 GOOS=linux go build -o /gibo

FROM alpine:3.18.2

WORKDIR /

COPY --from=build /gibo-go /gibo-go
RUN /gibo-go update
COPY --from=build /gibo /gibo
RUN /gibo update

ENTRYPOINT [ "/gibo-go" ]
ENTRYPOINT [ "/gibo" ]
28 changes: 14 additions & 14 deletions README.md
Original file line number Diff line number Diff line change
@@ -1,51 +1,51 @@
# gibo-go: fast access to .gitignore boilerplates
# gibo: fast access to .gitignore boilerplates

**gibo-go** (short for .gitignore boilerplates in Go) is a command-line tool to help you easily access .gitignore boilerplates from [github.com/github/gitignore](https://github.com/github/gitignore).
**gibo** (short for .gitignore boilerplates in Go) is a command-line tool to help you easily access .gitignore boilerplates from [github.com/github/gitignore](https://github.com/github/gitignore).

It is a reimplementation of [gibo](https://github.com/simonwhitaker/gibo), in Go.

## Typical usage

```console
$ gibo-go dump Swift Xcode >> .gitignore
$ gibo dump Swift Xcode >> .gitignore
```

For additional usage instructions, run `gibo-go help`.
For additional usage instructions, run `gibo help`.

## Installation

### Using Homebrew

```sh
brew install simonwhitaker/tap/gibo-go
brew install simonwhitaker/tap/gibo
```

### Using Chocolatey

```
choco install gibo-go
choco install gibo
```

### Using the Go toolchain

Or install using `go install`:

```sh
go install github.com/simonwhitaker/gibo-go@latest
go install github.com/simonwhitaker/gibo@latest
```

### Building from source

Clone the repo, then:

```sh
cd gibo-go
cd gibo
go install .
```

### Downloading a binary

Download the latest [release](https://github.com/simonwhitaker/gibo-go/releases) for your platform, then put `gibo-go` (or `gibo-go.exe`) somewhere on your path.
Download the latest [release](https://github.com/simonwhitaker/gibo/releases) for your platform, then put `gibo` (or `gibo.exe`) somewhere on your path.

### Installation on Docker

Expand All @@ -56,18 +56,18 @@ Coming soon
See the instructions at:

```
gibo-go completion
gibo completion
```

## Use gibo-go to generate .hgignore files
## Use gibo to generate .hgignore files

The `glob` .hgignore syntax for Mercurial is compatible with .gitignore syntax. This means that you can use gibo-go to generate .hgignore files, as long as the .hgignore files use the `glob` syntax:
The `glob` .hgignore syntax for Mercurial is compatible with .gitignore syntax. This means that you can use gibo to generate .hgignore files, as long as the .hgignore files use the `glob` syntax:

```sh
echo 'syntax: glob' > .hgignore
gibo-go dump Python >> .hgignore
gibo dump Python >> .hgignore
```

## Credits

gibo-go was written by Simon Whitaker ([@s1mn](http://twitter.com/s1mn))
gibo was written by Simon Whitaker ([@s1mn](http://twitter.com/s1mn))
2 changes: 1 addition & 1 deletion cmd/dump.go
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@ package cmd
import (
"log"

"github.com/simonwhitaker/gibo-go/utils"
"github.com/simonwhitaker/gibo/utils"
"github.com/spf13/cobra"
)

Expand Down
4 changes: 2 additions & 2 deletions cmd/gibo.go
Original file line number Diff line number Diff line change
Expand Up @@ -17,8 +17,8 @@ func init() {
}

var giboCmd = &cobra.Command{
Use: "gibo-go",
Short: "gibo-go is a command-line tool for easily accessing gitignore boilerplates",
Use: "gibo",
Short: "gibo is a command-line tool for easily accessing gitignore boilerplates",
}

func Execute() {
Expand Down
2 changes: 1 addition & 1 deletion cmd/list.go
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,7 @@ import (
"log"
"os"

"github.com/simonwhitaker/gibo-go/utils"
"github.com/simonwhitaker/gibo/utils"
"github.com/spf13/cobra"
"golang.org/x/term"
)
Expand Down
4 changes: 2 additions & 2 deletions cmd/root.go
Original file line number Diff line number Diff line change
Expand Up @@ -3,13 +3,13 @@ package cmd
import (
"fmt"

"github.com/simonwhitaker/gibo-go/utils"
"github.com/simonwhitaker/gibo/utils"
"github.com/spf13/cobra"
)

var rootCmd = &cobra.Command{
Use: "root",
Short: "Show the directory where gibo-go stores its boilerplates",
Short: "Show the directory where gibo stores its boilerplates",
Run: func(cmd *cobra.Command, args []string) {
fmt.Println(utils.RepoDir())
},
Expand Down
2 changes: 1 addition & 1 deletion cmd/search.go
Original file line number Diff line number Diff line change
Expand Up @@ -7,7 +7,7 @@ import (
"path/filepath"
"strings"

"github.com/simonwhitaker/gibo-go/utils"
"github.com/simonwhitaker/gibo/utils"
"github.com/spf13/cobra"
)

Expand Down
2 changes: 1 addition & 1 deletion cmd/update.go
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,7 @@ import (
"fmt"
"log"

"github.com/simonwhitaker/gibo-go/utils"
"github.com/simonwhitaker/gibo/utils"
"github.com/spf13/cobra"
)

Expand Down
2 changes: 1 addition & 1 deletion cmd/version.go
Original file line number Diff line number Diff line change
Expand Up @@ -18,7 +18,7 @@ var (

var versionCmd = &cobra.Command{
Use: "version",
Short: "Show the current version number of gibo-go",
Short: "Show the current version number of gibo",
Run: func(cmd *cobra.Command, args []string) {
fmt.Printf("%v v%v, commit %v, built on %v\n", filepath.Base(os.Args[0]), version, commit, date)
},
Expand Down
2 changes: 1 addition & 1 deletion go.mod
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
module github.com/simonwhitaker/gibo-go
module github.com/simonwhitaker/gibo

go 1.20

Expand Down
2 changes: 1 addition & 1 deletion main.go
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
package main

import "github.com/simonwhitaker/gibo-go/cmd"
import "github.com/simonwhitaker/gibo/cmd"

func main() {
cmd.Execute()
Expand Down
6 changes: 3 additions & 3 deletions tools/delete-windows-release.sh
Original file line number Diff line number Diff line change
Expand Up @@ -11,6 +11,6 @@ fi
gh release view "$tag" >/dev/null || exit 1

gh release delete-asset -y "$tag" checksums.windows.txt
gh release delete-asset -y "$tag" gibo-go_Windows_x86_64.zip
gh release delete-asset -y "$tag" gibo-go_Windows_i386.zip
gh release delete-asset -y "$tag" gibo-go_Windows_arm64.zip
gh release delete-asset -y "$tag" gibo_Windows_x86_64.zip
gh release delete-asset -y "$tag" gibo_Windows_i386.zip
gh release delete-asset -y "$tag" gibo_Windows_arm64.zip
2 changes: 1 addition & 1 deletion utils/utils.go
Original file line number Diff line number Diff line change
Expand Up @@ -91,7 +91,7 @@ func PrintBoilerplate(name string) error {
relativePath = strings.ReplaceAll(relativePath, "\\", "/")
}

fmt.Println("### Generated by gibo-go (https://github.com/simonwhitaker/gibo-go)")
fmt.Println("### Generated by gibo (https://github.com/simonwhitaker/gibo)")
fmt.Printf("### %v%v\n\n", remoteWebRoot, relativePath)
if err != nil {
return err
Expand Down

0 comments on commit 597ab86

Please sign in to comment.