Skip to content

Commit

Permalink
feat: add shellcheckrc and editorconfig
Browse files Browse the repository at this point in the history
  • Loading branch information
M0Rf30 committed Oct 21, 2023
1 parent a1911b3 commit 564fa15
Show file tree
Hide file tree
Showing 3 changed files with 21 additions and 4 deletions.
14 changes: 14 additions & 0 deletions .editorconfig
Original file line number Diff line number Diff line change
@@ -0,0 +1,14 @@
# top-most EditorConfig file
root = true

[{go.mod,go.sum,*.go,.gitmodules}]
indent_style = tab
indent_size = 4

[PKGBUILD]
indent_style = space
indent_size = 2
end_of_line = lf
charset = utf-8
trim_trailing_whitespace = true
insert_final_newline = false
2 changes: 2 additions & 0 deletions .shellcheckrc
Original file line number Diff line number Diff line change
@@ -0,0 +1,2 @@
# Disable individual error codes
disable=SC2154,SC2164,SC2034
9 changes: 5 additions & 4 deletions examples/yap/PKGBUILD
Original file line number Diff line number Diff line change
Expand Up @@ -37,7 +37,8 @@ build() {
-buildvcs=false \
-ldflags="-w -s -linkmode=external \
-X main.version=${pkgver}" \
cmd
-o yap \
cmd/yap/main.go
}

package() {
Expand All @@ -50,11 +51,11 @@ package() {
mkdir -p "${pkgdir}/usr/share/zsh/site-functions/"
mkdir -p "${pkgdir}/usr/share/fish/vendor_completions.d/"

./"${pkgname}" completion bash > \
./${pkgname} completion bash > \
"${pkgdir}/usr/share/bash-completion/completions/${pkgname}"
./"${pkgname}" completion zsh > \
./${pkgname} completion zsh > \
"${pkgdir}/usr/share/zsh/site-functions/_${pkgname}"
./"${pkgname}" completion fish > \
./${pkgname} completion fish > \
"${pkgdir}/usr/share/fish/vendor_completions.d/${pkgname}.fish"

install -Dm 644 -t \
Expand Down

0 comments on commit 564fa15

Please sign in to comment.