Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

use "standard" posix directory variables #67

Open
wants to merge 4 commits into
base: master
Choose a base branch
from

Conversation

git-issue.sh Outdated Show resolved Hide resolved
Copy link
Owner

@dspinellis dspinellis left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Excellent, thank you! I think we should remove the library detection while at it.

@r2evans
Copy link
Author

r2evans commented Feb 5, 2020

If you remove all library detection, then won't that also remove the option for a personal installation?

### Personal installation
Clone the repo and register a git alias to the `git-issue.sh` script:

```
git config --global alias.issue '!'"${REPO_PATH}/git-issue.sh"
```

Perhaps it would be better to search $(dirname $0)/../lib only if the preferred path is not found?

@dspinellis
Copy link
Owner

Right! Keep only the $0 check?

@r2evans
Copy link
Author

r2evans commented Feb 5, 2020

That is, perhaps we can trim the list of possibles down a bit, and make the test a little more specific:

 # Rationale: Word splitting not an issue
+LIB_PATH="$(dirname $0)/../libexec/git-issue:$LD_LIBRARY_PATH:/usr/local/libexec/git-issue:/usr/libexec/git-issue"
-LIB_PATH="/usr/local/libexec/git-issue:$(dirname $0)/../libexec/git-issue"
 if [ "x$GIT_ISSUE_LIB_PATH" != x ] ; then
   LIB_PATH="$GIT_ISSUE_LIB_PATH"
 fi
 for i in ${LIB_PATH} ; do
-  if [ -d "${i}" ] ; then
+  if [ -d "${i}" -a -f "${i}/import-export.sh" ] ; then
     MY_LIB="${i}"

Bill Evans added 3 commits February 5, 2020 14:27
[SC2166](https://github.com/koalaman/shellcheck/wiki/SC2166)
incompletely written, but essentially:

`test aa -a bb` is obsolete (not 'not well defined')
@r2evans
Copy link
Author

r2evans commented Feb 5, 2020

Sorry, I see the failed test, but I don't know what's causing it. It's likely in the hard-coded LIB_PATH checks, but since .issues is not being created with test.sh it all tumbles from there. I'll check back later.

@r2evans
Copy link
Author

r2evans commented Feb 5, 2020

I have a local fix that is creating .issues but is still marking the test as failed. The reason, I think, is that gi.sh init is creating a new log entry and leaving several files changed.

On my windows test machine, I see this artifact... any pointers?

$ git status
On branch fix/64_posix_makefile
nothing to commit, working tree clean

r2@d2sb2 MINGW64 ~/Projects/git-issue/_64_posix (fix/64_posix_makefile)
$ ./gi.sh init
Initialized empty issues repository in /c/Users/r2/Projects/git-issue/_64_posix/.issues

r2@d2sb2 MINGW64 ~/Projects/git-issue/_64_posix (fix/64_posix_makefile)
$ git status
On branch fix/64_posix_makefile
Changes not staged for commit:
  (use "git add/rm <file>..." to update what will be committed)
  (use "git restore <file>..." to discard changes in working directory)
        modified:   README.md
        deleted:    config
        deleted:    templates/comment
        deleted:    templates/description

no changes added to commit (use "git add" and/or "git commit -a")

r2@d2sb2 MINGW64 ~/Projects/git-issue/_64_posix (fix/64_posix_makefile)
$ git diff README.md
diff --git a/README.md b/README.md
index f440ebb..468599a 100644
--- a/README.md
+++ b/README.md
@@ -1,2 +1,539 @@
-This is an distributed issue tracking repository based on Git.
-Visit [git-issue](https://github.com/dspinellis/git-issue) for more information.
+[![Build Status](https://travis-ci.org/eellak/gsoc2019-git-issue.svg?branch=gsoc-2019)](https://travis-ci.org/eellak/gsoc2019-git-issue)
+# git-issue
+
+This is a minimalist decentralized issue management system based on Git,
+offering (optional) biderectional integration with GitHub and GitLab issue management.
+It has the following advantages over other systems.
.........

@dspinellis
Copy link
Owner

Not sure what is going on with the failed test. Regarding library detection, how about having the personal installation involve specifying the various directories through =$(pwd)?

@r2evans
Copy link
Author

r2evans commented Feb 11, 2020

(I apologize, I'm at a conference and unable to put any time into this for a bit...)

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

2 participants