commit 98bd7926eca68eb7a3f6e36b59bbbe72ea10923f27069837f7d8770edcef7522 Author: Martin Pluskal Date: Mon Dec 6 11:41:31 2021 +0000 Accepting request 935787 from home:Orville:Devel GLab is an unoffical command line tools for GitLab works just like Github's gh. OBS-URL: https://build.opensuse.org/request/show/935787 OBS-URL: https://build.opensuse.org/package/show/devel:tools:scm/glab?expand=0&rev=1 diff --git a/.gitattributes b/.gitattributes new file mode 100644 index 0000000..9b03811 --- /dev/null +++ b/.gitattributes @@ -0,0 +1,23 @@ +## Default LFS +*.7z filter=lfs diff=lfs merge=lfs -text +*.bsp filter=lfs diff=lfs merge=lfs -text +*.bz2 filter=lfs diff=lfs merge=lfs -text +*.gem filter=lfs diff=lfs merge=lfs -text +*.gz filter=lfs diff=lfs merge=lfs -text +*.jar filter=lfs diff=lfs merge=lfs -text +*.lz filter=lfs diff=lfs merge=lfs -text +*.lzma filter=lfs diff=lfs merge=lfs -text +*.obscpio filter=lfs diff=lfs merge=lfs -text +*.oxt filter=lfs diff=lfs merge=lfs -text +*.pdf filter=lfs diff=lfs merge=lfs -text +*.png filter=lfs diff=lfs merge=lfs -text +*.rpm filter=lfs diff=lfs merge=lfs -text +*.tbz filter=lfs diff=lfs merge=lfs -text +*.tbz2 filter=lfs diff=lfs merge=lfs -text +*.tgz filter=lfs diff=lfs merge=lfs -text +*.ttf filter=lfs diff=lfs merge=lfs -text +*.txz filter=lfs diff=lfs merge=lfs -text +*.whl filter=lfs diff=lfs merge=lfs -text +*.xz filter=lfs diff=lfs merge=lfs -text +*.zip filter=lfs diff=lfs merge=lfs -text +*.zst filter=lfs diff=lfs merge=lfs -text diff --git a/.gitignore b/.gitignore new file mode 100644 index 0000000..57affb6 --- /dev/null +++ b/.gitignore @@ -0,0 +1 @@ +.osc diff --git a/_service b/_service new file mode 100644 index 0000000..6e0ad3b --- /dev/null +++ b/_service @@ -0,0 +1,17 @@ + + + https://github.com/profclems/glab.git + git + v1.21.1 + @PARENT_TAG@ + v(.*) + glab + enable + + + + *.tar + xz + + + diff --git a/glab-1.21.1.tar.xz b/glab-1.21.1.tar.xz new file mode 100644 index 0000000..c21d58e --- /dev/null +++ b/glab-1.21.1.tar.xz @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:5fed6956d28acb83fbb8018d7954ad435bb1efd335e064bcc016e4fb1a35dbc2 +size 16343016 diff --git a/glab-vendor.tar.gz b/glab-vendor.tar.gz new file mode 100644 index 0000000..2ac024c --- /dev/null +++ b/glab-vendor.tar.gz @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:233377bab355d5d9fab6b6efebc415745236fb3b37cbbd428d03c09b9abfeda6 +size 6157365 diff --git a/glab.changes b/glab.changes new file mode 100644 index 0000000..307c47c --- /dev/null +++ b/glab.changes @@ -0,0 +1,24 @@ +------------------------------------------------------------------- +Sun Dec 05 11:42:32 UTC 2021 - Orville Q. Song + +- Update to version 1.21.1: + * fix debian packaging installer location + * auth login use OverridableDefault + * Login using default hostname string + * Move glinstance to pkg + * {go.mod,go.sum}: update dependencies + * api: fix wrong comment + * fix: error 404 when creating release + * Handle paginated response in pipeline.GetPipelineJobs + * Update ssh-key.go + * feat(cmdutils): Add group milestones to the prompt + +------------------------------------------------------------------- +Sat Dec 4 16:39:53 UTC 2021 - Orville Q. Song + +- Init glab Package + +An open-source GitLab command line tool bringing GitLab's cool features to your command line. + +Current Version: v1.21.1 +Commit Hash: 5cb2858d1fb7a5317e89259fc4ac135414e99be2 diff --git a/glab.spec b/glab.spec new file mode 100644 index 0000000..f3b7a5a --- /dev/null +++ b/glab.spec @@ -0,0 +1,146 @@ +# spec file for package glab +# +# Copyright (c) 2021 Orville Q. Song +# +# All modifications and additions to the file contributed by third parties +# remain the property of their copyright owners, unless otherwise agreed +# upon. The license for this file, and modifications and additions to the +# file, is the same license as for the pristine package itself (unless the +# license for the pristine package is not an Open Source License, in which +# case the license is the MIT License). An "Open Source License" is a +# license that conforms to the Open Source Definition (Version 1.9) +# published by the Open Source Initiative. + +# Please submit bugfixes or comments via https://bugs.opensuse.org/ +# + +%global build_date %(date +%Y-%m-%d) + +%global provider github +%global provider_tld com +%global project profclems +%global repo glab +%global provider_prefix %{provider}.%{provider_tld}/%{project} +%global import_path %{provider_prefix}/%{repo} + +Name: glab +Version: 1.21.1 +Release: 0 +Summary: An open-source GitLab command line tool +License: MIT +Group: Development/Tools/Other +URL: https://github.com/profclems/glab +Source0: %{name}-%{version}.tar.xz +Source1: %{name}-vendor.tar.gz +BuildRequires: golang-packaging +BuildRequires: golang(API) >= 1.16 +BuildRequires: %{python_module Sphinx} +Suggests: glab-doc + +%description +glab is an open-source GitLab command line tool bringing GitLab's cool features to your command line. + +%package doc +Summary: Documentation for GLab +Group: Documentation/HTML +BuildArch: noarch + +%description doc +glab is an open-source GitLab command line tool bringing GitLab's cool features to your command line. + +%package bash-completion +Summary: Bash completion for %{name} +Group: System/Shells +Requires: %{name} = %{version} +Supplements: (%{name} and bash) +BuildArch: noarch + +%description bash-completion +Bash command line completion support for %{name}. + +%package fish-completion +Summary: Fish completion for %{name} +Group: System/Shells +Requires: %{name} = %{version} +Supplements: (%{name} and fish) +BuildArch: noarch + +%description fish-completion +Fish command line completion support for %{name}. + +%package zsh-completion +Summary: Zsh completion for %{name} +Group: System/Shells +Requires: %{name} = %{version} +Supplements: (%{name} and zsh) +BuildArch: noarch + +%description zsh-completion +Zsh command line completion support for %{name}. + +%{go_nostrip} +%{go_provides} + +%prep +%setup -q -n %{name}-%{version} +%setup -a1 %{SOURCE1} + +%build +%goprep . +mkdir -p vendor/%{provider_prefix} +ln -s . vendor/%{import_path} +%gobuild -mod=vendor -ldflags "-s -w -X main.version=%{version} -X main.build=%{build_date} -X main.debugMode=false" ./cmd/glab + +# Build HTML docs +go run -v -p 4 -x -mod=vendor ./cmd/gen-docs/ +make -C docs html + +# Build manpages +go run -v -p 4 -x -mod=vendor ./cmd/gen-docs/ -m --path ./docs/build/man +gzip -r ./docs/build/man + +# Generate completion files +go run -v -p 4 -x -mod=vendor ./cmd/glab/ completion -s bash > glab.bash +go run -v -p 4 -x -mod=vendor ./cmd/glab/ completion -s zsh > glab.zsh +go run -v -p 4 -x -mod=vendor ./cmd/glab/ completion -s fish > glab.fish + +%install +%goinstall + +# Install HTML docs +for i in $(find ./docs/build/html/ -type f | grep -vE "_source|.buildinfo|objects.inv"); do install -D -m0644 $i %{buildroot}%{_docdir}/%{name}/$(echo $i | sed -e s@^./docs/build/html/@@); done; + +# Install manpages +for i in $(find ./docs/build/man/ -type f); do install -D -m0644 $i %{buildroot}%{_mandir}/man1/$(echo $i | sed -e s@^./docs/build/man/@@); done; + +# Install comletion files +install -D -m0644 %{name}.zsh %{buildroot}%{_datadir}/zsh/site-functions/_%{name} +install -D -m0644 %{name}.fish %{buildroot}%{_datadir}/fish/vendor_completions.d/%{name}.fish +install -D -m0644 %{name}.bash %{buildroot}%{_datadir}/bash-completion/completions/%{name} + +%files +%defattr(-,root,root) +%license LICENSE +%doc README.md +%{_mandir}/*/* +%{_bindir}/%{name} + +%files doc +%defattr(-,root,root) +%{_docdir}/%{name} +%exclude %{_docdir}/%{name}/README.md + +%files bash-completion +%dir %{_datadir}/bash-completion/ +%{_datadir}/bash-completion/completions/ + +%files fish-completion +%dir %{_datadir}/fish/ +%{_datadir}/fish/vendor_completions.d/ + +%files zsh-completion +%dir %{_datadir}/zsh/ +%{_datadir}/zsh/site-functions/ + + +%changelog