From 05df5a21522eb28aeb86bb7522f9639cae99086e9c55cc8eb1d7d03d4226a15f Mon Sep 17 00:00:00 2001 From: Olav Reinert Date: Wed, 6 Jun 2018 19:55:02 +0000 Subject: [PATCH] OBS-URL: https://build.opensuse.org/package/show/utilities/homeshick?expand=0&rev=9 --- 1.0.0.tar.gz | 3 -- default-location.patch | 64 ------------------------------------------ homeshick.changes | 11 ++++++++ homeshick.rpmlintrc | 1 + homeshick.spec | 13 +++++---- suse-packaging.patch | 24 ++++++++++++++++ v1.1.0.tar.gz | 3 ++ 7 files changed, 46 insertions(+), 73 deletions(-) delete mode 100644 1.0.0.tar.gz delete mode 100644 default-location.patch create mode 100644 suse-packaging.patch create mode 100644 v1.1.0.tar.gz diff --git a/1.0.0.tar.gz b/1.0.0.tar.gz deleted file mode 100644 index 91ba84e..0000000 --- a/1.0.0.tar.gz +++ /dev/null @@ -1,3 +0,0 @@ -version https://git-lfs.github.com/spec/v1 -oid sha256:8bd3c46f1cfd68d82d97fa72a68a07c966092c77f276d1335cb390b2ec6062bf -size 27691 diff --git a/default-location.patch b/default-location.patch deleted file mode 100644 index 65369e7..0000000 --- a/default-location.patch +++ /dev/null @@ -1,64 +0,0 @@ -diff --git a/bin/homeshick b/bin/homeshick -index 46fd1da..b1e4a6f 100755 ---- a/bin/homeshick -+++ b/bin/homeshick -@@ -2,7 +2,7 @@ - - repos="$HOME/.homesick/repos" - # Include all helper functions. We will include the required command function later on. --homeshick=${HOMESHICK_DIR:-$HOME/.homesick/repos/homeshick} -+homeshick=${HOMESHICK_DIR:-/usr/share/homeshick} - source "$homeshick/lib/exit_status.sh" - source "$homeshick/lib/fs.sh" - source "$homeshick/lib/git.sh" -diff --git a/bin/homeshick.csh b/bin/homeshick.csh -index 2814f10..1c2c9a2 100644 ---- a/bin/homeshick.csh -+++ b/bin/homeshick.csh -@@ -1,6 +1,6 @@ - # This helper script should be sourced via an alias, e.g. - # --# alias homeshick "source $HOME/.homesick/repos/homeshick/bin/homeshick.csh" -+# alias homeshick "source /usr/share/homeshick/bin/homeshick.csh" - # - if ( "$1" == "cd" && "x$2" != "x" ) then - if ( -d "$HOME/.homesick/repos/$2/home" ) then -@@ -12,6 +12,6 @@ else - if ( $?HOMESHICK_DIR ) then - $HOMESHICK_DIR/bin/homeshick $* - else -- $HOME/.homesick/repos/homeshick/bin/homeshick $* -+ /usr/share/homeshick/bin/homeshick $* - endif - endif -diff --git a/homeshick.fish b/homeshick.fish -index 10359ee..51cd0a2 100644 ---- a/homeshick.fish -+++ b/homeshick.fish -@@ -1,5 +1,5 @@ - # This script should be sourced in the context of your shell like so: --# source $HOME/.homesick/repos/homeshick/homeshick.fish -+# source /usr/share/homeshick/homeshick.fish - # Once the homeshick() function is defined, you can type - # "homeshick cd CASTLE" to enter a castle. - -@@ -9,6 +9,6 @@ function homeshick - else if set -q HOMESHICK_DIR - eval $HOMESHICK_DIR/bin/homeshick $argv - else -- eval $HOME/.homesick/repos/homeshick/bin/homeshick $argv -+ eval /usr/share/homeshick/bin/homeshick $argv - end - end -diff --git a/homeshick.sh b/homeshick.sh -index e8c2663..797731d 100644 ---- a/homeshick.sh -+++ b/homeshick.sh -@@ -7,6 +7,6 @@ function homeshick() { - if [ "$1" = "cd" ] && [ -n "$2" ]; then - cd "$HOME/.homesick/repos/$2" - else -- "${HOMESHICK_DIR:-$HOME/.homesick/repos/homeshick}/bin/homeshick" "$@" -+ "${HOMESHICK_DIR:-/usr/share/homeshick}/bin/homeshick" "$@" - fi - } diff --git a/homeshick.changes b/homeshick.changes index 1f58c3e..d308377 100644 --- a/homeshick.changes +++ b/homeshick.changes @@ -1,3 +1,14 @@ +------------------------------------------------------------------- +Wed Jun 6 19:43:22 UTC 2018 - seroton10@gmail.com + +- Upgrade to version 1.1.0: + * symlinks are now relative (useful when linking for a chrooted environment + or when renaming the home folder) + * fish shell completion (guide in wiki) + * homeshick.sh can now be sourced from dash as well + * the entire codebase is now linted with shellcheck + * loads of minor bugfixes + ------------------------------------------------------------------- Tue May 26 16:28:59 UTC 2015 - seroton10@gmail.com diff --git a/homeshick.rpmlintrc b/homeshick.rpmlintrc index 3fc8cf9..50e83c9 100644 --- a/homeshick.rpmlintrc +++ b/homeshick.rpmlintrc @@ -1,2 +1,3 @@ addFilter("non-executable-script .*/usr/share/homeshick/lib") +addFilter("env-script-interpreter .*/usr/share/homeshick/lib") diff --git a/homeshick.spec b/homeshick.spec index e3b9eb4..a9ccb66 100644 --- a/homeshick.spec +++ b/homeshick.spec @@ -1,7 +1,7 @@ # # spec file for package homeshick # -# Copyright (c) 2015 SUSE LINUX GmbH, Nuernberg, Germany. +# Copyright (c) 2018 SUSE LINUX GmbH, Nuernberg, Germany. # # All modifications and additions to the file contributed by third parties # remain the property of their copyright owners, unless otherwise agreed @@ -17,16 +17,16 @@ Name: homeshick -Version: 1.0.0 +Version: 1.1.0 Release: 0 Summary: Dotfile synchronizer based on Git and Bash License: MIT Group: Productivity/File utilities Url: https://github.com/andsens/homeshick -Source0: https://github.com/andsens/homeshick/archive/%{version}.tar.gz +Source0: https://github.com/andsens/homeshick/archive/v%{version}.tar.gz Source1: README-openSUSE.md Source99: homeshick.rpmlintrc -Patch0: default-location.patch +Patch0: suse-packaging.patch BuildRequires: expect BuildRequires: git >= 1.5 BuildRequires: iputils @@ -68,14 +68,15 @@ ln -s %{_datadir}/%{name}/bin/homeshick %{buildroot}%{_bindir}/%{name} cp %{SOURCE1} . %check -# only run tests if bats is available +# run tests if bats is available if type bats &>/dev/null; then HOMESHICK_DIR=%{buildroot}%{_datadir}/%{name} bats test/suites fi %files %defattr(-,root,root) -%doc README.md README-openSUSE.md LICENSE CONTRIBUTING.md +%doc README.md README-openSUSE.md CONTRIBUTING.md +%license LICENSE %{_datadir}/%{name} %{_bindir}/homeshick diff --git a/suse-packaging.patch b/suse-packaging.patch new file mode 100644 index 0000000..0e0c1ea --- /dev/null +++ b/suse-packaging.patch @@ -0,0 +1,24 @@ +diff -c -r homeshick-1.1.0-orig/bin/homeshick homeshick-1.1.0/bin/homeshick +*** homeshick-1.1.0-orig/bin/homeshick 2018-04-12 21:52:30.000000000 +0200 +--- homeshick-1.1.0/bin/homeshick 2018-06-06 21:28:43.247842198 +0200 +*************** +*** 1,4 **** +! #!/usr/bin/env bash + + repos="$HOME/.homesick/repos" + # Include all helper functions. We will include the required command function later on. +--- 1,4 ---- +! #!/bin/bash + + repos="$HOME/.homesick/repos" + # Include all helper functions. We will include the required command function later on. +diff -c -r homeshick-1.1.0-orig/homeshick.sh homeshick-1.1.0/homeshick.sh +*** homeshick-1.1.0-orig/homeshick.sh 2018-04-12 21:52:30.000000000 +0200 +--- homeshick-1.1.0/homeshick.sh 2018-06-06 21:32:39.506072561 +0200 +*************** +*** 1,4 **** +- #!/usr/bin/env sh + # This script should be sourced in the context of your shell like so: + # source $HOME/.homeshick/repos/.homeshick/homeshick.sh + # Once the homeshick() function is defined, you can type +--- 1,3 ---- diff --git a/v1.1.0.tar.gz b/v1.1.0.tar.gz new file mode 100644 index 0000000..bf77a81 --- /dev/null +++ b/v1.1.0.tar.gz @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:1894675f4f2ab002a97574445c03c7c7336c996c01023b7fc5e6668dce7d5a3c +size 33345