Taylor Blau
5dc2532cc7
commands/command_lock: resolve symbolic links in cwd
2018-05-04 15:28:16 -07:00
rick olson
3e43ac795d
commands: remove internal refUpdate type in favor of git.RefUpdate
2018-01-05 15:22:25 -07:00
rick olson
9027b941e8
locking: add optional RemoteRef field to Client
2017-12-06 18:07:34 -07:00
rick olson
be55d7905d
locking: teach LockFile() to send remote refspec
2017-12-06 15:50:08 -07:00
rick olson
6eed720b61
commands: remove any cfg.Remote() calls from Command flags
2017-10-27 15:07:36 -06:00
rick olson
19c7787617
config: make (*Configuration) CurrentRemote private, add Remote() and SetRemote()
2017-10-27 15:00:07 -06:00
Taylor Blau
f1b6434516
commands/command_lock: print true locked path instead of argument
2017-04-07 10:55:28 -04:00
Taylor Blau
9de10e22cc
commands/command_lock: cross-platform normalization of lock paths
2017-04-07 10:54:59 -04:00
risk danger olson
5604e29ef3
Print error causes to stderr
2017-02-24 16:31:27 -07:00
risk danger olson
d292a19f51
commands: use active voice for lock messages
2017-02-23 12:54:57 -07:00
risk danger olson
99c3b4df8d
commands: allow lock commands to be used without env flag
2017-02-15 11:11:23 -07:00
risk danger olson
cf57991c89
commands: cast the rune as a string
2017-02-10 15:09:42 -07:00
risk danger olson
c85068a284
commands: trim path separator on windows too
2017-02-10 15:08:25 -07:00
risk danger olson
e6d44cb2be
commands: use TrimPrefix for clarity
2017-02-10 14:41:15 -07:00
risk danger olson
b02f5701bd
Fix lfs unlock --force
on a missing file
2017-02-09 14:03:24 -07:00
risk danger olson
da415d520c
merge conflicts from master
2017-01-06 14:33:54 -07:00
risk danger olson
621bafd416
commands: unexport the client helpers
2017-01-03 15:57:17 -07:00
risk danger olson
a998543418
locking: remove dependency on config pkg
2017-01-03 14:13:59 -07:00
risk danger olson
f1da0fb8e2
locking: remove dependency on config.Configuration
2017-01-03 13:38:15 -07:00
risk danger olson
ef70cf9dc1
locking: use lfsapi for searches
2017-01-03 13:05:30 -07:00
risk danger olson
7929df8664
commands: add json output support
2016-12-27 17:05:48 -07:00
Steve Streeting
3ea24f1647
Add lock tests and tweak cache to store entire locks
2016-12-12 10:26:12 +00:00
Steve Streeting
7ac855b684
Add Close func to lock Client to save cache
2016-12-12 10:26:12 +00:00
Steve Streeting
de63cd1d46
Remove remote arg from lock methods, configuration handles this now
2016-12-05 11:25:02 +00:00
Steve Streeting
491070607c
Create a Client
stateful wrapper for locking API
2016-12-05 09:47:29 +00:00
Steve Streeting
5cd9dcee01
Drop channel wrappers in locking pkg, simplify & make self-contained
2016-11-28 17:01:06 +00:00
Steve Streeting
092c879dbe
Move lock implementation to separate package
2016-11-28 16:20:04 +00:00
risk danger olson
bba8f3b876
update package imports
2016-11-15 10:01:18 -07:00
risk danger olson
a12cdc889f
RegisterCommand() can no longer disable commands
...
the config is available at init(), so isCommandEnabled() checks can be
pulled out of the RegisterCommand() callback, simplifying its signature.
2016-09-01 10:09:38 -06:00
risk danger olson
a2b1cc5911
commands: try out RegisterCommand()
2016-08-31 10:17:13 -06:00
Taylor Blau
0f63130c23
commands, lfs: resolve localstorage in PreRun, not init
2016-08-22 16:21:04 -06:00
risk danger olson
98af5944e1
build commands outside of package init()
2016-08-10 09:33:25 -06:00
risk danger olson
7457375b1e
rename commands.Config to commands.cfg
2016-07-21 16:37:53 -06:00
risk danger olson
ed01a95449
Use commands.Config instead of config.Config
2016-07-21 15:27:30 -06:00
Taylor Blau
ab9842c3f9
commands: use config's GetenvBool
, add tests
2016-07-21 10:38:59 -06:00
Taylor Blau
36b0664fe0
commands/test: make lock commands opt-in using GITLFSLOCKSENABLED=1
...
To prepare for the upcoming release of Git LFS v1.3, the `git-lfs lock` and
`git-lfs locks` commands are now hidden behind a enviornment variable
`GITLFSLOCKSENABLED`. Since most (all?) implementations of LFS do not yet
support this new locking API, it makes sense to allow users to experiment with
the command while at the same time, not making it a "full" part of the release.
If users wish to run any `git-lfs lock{,s}` command, they may do so according
to the following:
```
$ GITLFSLOCKSEANBLED=1 git lfs lock <flags> [args]
$ GITLFSLOCKSEANBLED=1 git lfs locks <flags> [args]
```
This commit, when applied, adds two new things:
1. The `isCommandEnabled(cmd string) bool` func in the commands package. This
new func checks the OS's enviornment variables and determines whether or not
a command is "enabled".
2. Updates the `lock` and `locks` tests to use the
GITLFSLOCKSENABLED=1 flag such that they are able to run.
Since the `isCommandEnabled` func defaults to "false", it should only guard
commands which are deemed "experimental", as noted in the godoc.
2016-07-21 10:07:06 -06:00
Taylor Blau
8fb44158b5
locks: path formatting changes
...
* strip leading slash from paths
* disallow directory locking (+ test)
2016-06-04 11:26:36 -06:00
Taylor Blau
21b92381f4
commands/lock: properly trim prefix from lock path
2016-06-03 14:59:13 -06:00
Taylor Blau
36804efc84
commands_{lock,locks,unlock}: implement lockPath for great good
2016-06-03 09:22:20 -06:00
Taylor Blau
fad308366f
commands_{lock,locks,unlock}: allow custom --remote specification
2016-06-03 09:22:20 -06:00
Taylor Blau
2680afc34a
commands_{lock,unlock,locks}: implement lock commands
2016-06-03 09:22:19 -06:00