Age | Commit message (Collapse) | Author |
|
Functions called by call-with-file-in-git may expect to read files
directly off the filesystem. These functions are not all within the
user's control and cannot be rewritten to do otherwise. It is more
robust to provide a filesystem checkout of the git repository like
these functions expect. In this commit, we deprecate
call-with-file-in-git and replace calls to it with
call-with-input-file. These invocations have been arranged such that
they all happen at the top level of a repository checkout.
* tissue/git.scm (call-with-file-in-git): Delete function.
* .dir-locals.el (scheme-mode): Unregister it.
* bin/tissue (tissue-show, load-config),
tissue/file-document.scm (file-text, read-gemtext-document),
tissue/issue.scm (read-gemtext-issue): Replace call-with-file-in-git
with call-with-input-file.
(pull, tissue-web): Call load-config from the top level of a
repository checkout.
|
|
Now that snippet source texts are interred into the xapian index, the
web server does not need a repository checkout.
* bin/tissue (tissue-web): Do not temporarily checkout repositories
being served.
* tissue/web/server.scm (handler): Do not change into repository
directory.
* tissue/git.scm (call-with-temporary-checkouts): Delete function.
* .dir-locals.el (scheme-mode): Unregister it.
|
|
* tissue/git.scm (call-with-temporary-checkout): Create temporary
checkout in temporary directory, not in current directory.
|
|
* tissue/git.scm (call-with-temporary-checkout,
call-with-temporary-checkouts): New public functions.
* .dir-locals.el (scheme-mode): Set scheme-indent-function of
call-with-temporary-checkout and call-with-temporary-checkouts to 1.
|
|
* tissue/git.scm (commit-deltas): Rename to ...
(commit-file-changes): ... this. Return list of pairs mapping old
files to new files.
(file-modification-table): Use commit-file-changes instead of
commit-deltas. Adapt to new return value.
* tests/git.scm: New file.
* .dir-locals.el (scheme-mode): Set scheme-indent-function for
with-variable and with-variables.
|
|
* tissue/git.scm (git-top-level): Find git top level correctly even in
bare repositories.
|
|
* tissue/document.scm (slot-set): Markup docstring in texinfo syntax.
* tissue/file-document.scm (read-gemtext-document): Markup docstring
in texinfo syntax.
* tissue/git.scm (git-tracked-files): Markup docstring in texinfo
syntax.
* tissue/issue.scm (read-gemtext-issue): Markup docstring in texinfo
syntax.
* tissue/tissue.scm (gemtext-files-in-directory): Markup docstring in
texinfo syntax.
* tissue/web/static.scm (exporter, copier, gemtext-exporter,
skribe-exporter): Markup docstrings in texinfo syntax.
|
|
This generalization of call-with-file-in-git permits preferential
reading of uncommitted changes, and reading of files external to the
git repository.
* tissue/git.scm (call-with-file-in-git): Prefer reading checked out
files.
|
|
* tissue/git.scm: Import (rnrs exceptions).
(git-tracked-file?): New public function.
|
|
* tissue/git.scm (commit-author-date): New public function.
(commit-date): Delete function.
* tissue/issue.scm (read-gemtext-issue): Use commit-author-date
instead of commit-date.
|
|
* tissue/git.scm: Import (rnrs conditions) and (srfi srfi-1).
(condition-git-error): New public function.
* bin/tissue (default-configuration): Use condition-git-error.
|
|
* tissue/git.scm: Import dereference-pointer and string->pointer
from (system foreign).
(reference-set-target!): New public function.
|
|
* tissue/git.scm: Import pointer->string from (system foreign).
(reference-symbolic-target): New public function.
|
|
* tissue/git.scm (%current-git-repository): New public parameter.
(current-git-repository): Use %current-git-repository.
|
|
* tissue/git.scm (git-top-level): Implement git-top-level in terms of
current-git-repository.
|
|
repository-open-ext obsoletes git-top-level.
* tissue/git.scm (current-git-repository): Implement using
repository-open-ext instead of git-top-level.
|
|
* tissue/git.scm: Import (bytestructures guile).
(clone-options): New function.
|
|
* tissue/git.scm (git-top-level): Fill docstring.
|
|
* tissue/git.scm (call-with-file-in-git): New public function.
|
|
The index is the staging area. We really only want to look at files
already committed into the git repository. In addition, a pleasant
side-effect is that this gets rid of many of the additional bindings
from libgit2.
* tissue/git.scm: Import only %null-pointer from (system foreign). Do
not import (bytestructures guile).
(pointer->bytestructure, bytestructure->pointer, pointer->index-time,
pointer->index-entry, repository-index, index-version,
index-entry-count, index-entry, index-entries): Delete functions.
(%oid, %index-time, %index-entry): Delete variables.
(<index-time>, <index-entry>): Delete types.
(head-tree): New function.
(git-tracked-files): Find git tracked files from HEAD, not from index.
|
|
While making the repository argument mandatory makes git-tracked-files
more of a pure function, users would still prefer to implicitly refer
to the current repository in their tissue.scm configuration files.
* tissue/git.scm (git-tracked-files): Make repository argument
optional.
|
|
* tissue/git.scm: Import (rnrs hashtables) and (ice-9 match).
(commit-deltas): New function.
(file-modification-table): New public function.
* tissue/issue.scm: Import (git).
(file-details): Do not lookup git history for file using `git log'.
(issues): Use file-modification-table to lookup git history.
|
|
* tissue/git.scm: Import (srfi srfi-19).
(commit-date): New public function.
|
|
* tissue/git.scm: Import %null-pointer from (system foreign).
(diff-find-similar!): New function.
|
|
Accepting a repository argument makes git-tracked-files a better
stand-alone utility.
* tissue/git.scm (git-tracked-files): Accept repository argument.
* tissue/tissue.scm (gemtext-files-in-directory): Pass repository
argument to git-tracked-files.
|
|
* tissue/git.scm (current-git-repository): New public function.
|
|
* tissue/git.scm: Import (rnrs arithmetic bitwise), (srfi
srfi-9), (git), (git types), and selected symbols from (system
foreign) and (bytestructures guile).
(pointer->bytestructure, bytestructure->pointer, pointer->index-time,
pointer->index-entry, repository-index, index-version,
index-entry-count, index-entry, index-entries):
New functions.
(%oid, %index-time, %index-entry): New variables
(<index-time>, <index-entry>): New types.
(git-tracked-files): Implement using guile-git.
|
|
* tissue/git.scm (git-top-level): Implement independent of the git
command.
|
|
* tissue/git.scm (git-top-level): New function.
* bin/tissue: Import (tissue git).
(load-config): Use git-top-level.
|
|
* tissue/git.scm: New file.
* tissue/issue.scm: Import (tissue git).
(issues): Use git-tracked-files.
|