Skip to content

Commit ace19ee

Browse files
committed
cleaning up src ^^
- rm `vendor` folder - bump ext dep. - github actions - ...
1 parent 253bb4e commit ace19ee

37 files changed

Lines changed: 288 additions & 10058 deletions

.github/workflows/release.yml

Lines changed: 29 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,29 @@
1+
name: goreleaser
2+
3+
on:
4+
push:
5+
tags:
6+
- '*'
7+
8+
permissions:
9+
contents: write
10+
11+
jobs:
12+
goreleaser:
13+
runs-on: ubuntu-latest
14+
steps:
15+
- uses: actions/checkout@v3
16+
with:
17+
fetch-depth: 0
18+
- run: git fetch --force --tags
19+
- uses: actions/setup-go@v3
20+
with:
21+
go-version: '>=1.19.2'
22+
cache: true
23+
- uses: goreleaser/goreleaser-action@v2
24+
with:
25+
distribution: goreleaser
26+
version: latest
27+
args: release --rm-dist
28+
env:
29+
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}

.gitignore

Lines changed: 1 addition & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,3 +1,2 @@
11
.idea/
2-
out/
3-
release/
2+
dist/

.golangci.yaml

Lines changed: 11 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,11 @@
1+
linters:
2+
enable-all: true
3+
disable:
4+
- forbidigo
5+
- funlen
6+
- lll
7+
- gochecknoglobals
8+
- paralleltest
9+
- scopelint
10+
- testpackage
11+
- varnamelen

.goreleaser.yml

Lines changed: 23 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,23 @@
1+
before:
2+
hooks:
3+
- go mod tidy
4+
builds:
5+
- env:
6+
- CGO_ENABLED=0
7+
goos:
8+
- linux
9+
- windows
10+
- darwin
11+
goarch:
12+
- amd64
13+
- arm64
14+
checksum:
15+
name_template: 'checksums.txt'
16+
snapshot:
17+
name_template: "{{ incpatch .Version }}-next"
18+
changelog:
19+
sort: asc
20+
filters:
21+
exclude:
22+
- '^docs:'
23+
- '^test:'

.pre-commit-config.yaml

Lines changed: 10 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,10 @@
1+
# todo add to CI
2+
repos:
3+
- repo: https://github.com/pre-commit/pre-commit-hooks
4+
rev: v4.3.0
5+
hooks:
6+
- id: check-case-conflict
7+
- id: trailing-whitespace
8+
- id: end-of-file-fixer
9+
- id: check-yaml
10+
- id: check-added-large-files

.travis.yml

Lines changed: 0 additions & 20 deletions
This file was deleted.

LICENSE

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
BSD 2-Clause License
22

3-
Copyright (c) 2017, AJ
3+
Copyright (c) 2022, AJ
44
All rights reserved.
55

66
Redistribution and use in source and binary forms, with or without

README.md

Lines changed: 2 additions & 18 deletions
Original file line numberDiff line numberDiff line change
@@ -2,32 +2,16 @@
22

33
A small tool for converting YAML files into JSON.
44

5-
## Installation
6-
7-
macOS
8-
```
9-
$ brew tap wakeful/selection
10-
$ brew install yaml2json
11-
```
12-
13-
Linux
14-
```
15-
curl -Lo yaml2json https://github.com/wakeful/yaml2json/releases/latest/download/yaml2json-linux-amd64 && chmod +x yaml2json && sudo mv yaml2json /usr/local/bin/
16-
```
17-
18-
src
19-
```
20-
go get -u github.com/wakeful/yaml2json
21-
```
22-
235
## Usage
246

257
stdin pipe:
8+
269
```
2710
cat file.yml | yaml2json
2811
```
2912

3013
or specify a file:
14+
3115
```
3216
yaml2json path/file.yml
3317
```

decode.go

Lines changed: 0 additions & 33 deletions
This file was deleted.

go.mod

Lines changed: 2 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -1,10 +1,5 @@
11
module github.com/wakeful/yaml2json
22

3-
go 1.12
3+
go 1.19
44

5-
require (
6-
github.com/go-yaml/yaml v2.1.0+incompatible
7-
github.com/kr/pretty v0.1.0 // indirect
8-
gopkg.in/check.v1 v1.0.0-20180628173108-788fd7840127 // indirect
9-
gopkg.in/yaml.v2 v2.2.2 // indirect
10-
)
5+
require gopkg.in/yaml.v2 v2.4.0

0 commit comments

Comments
 (0)