sam boyer
0070bb4e92
Add renameElseCopy(), useful for work in temp dirs
2017-01-04 17:19:32 -08:00
sam boyer
ffd999ed29
Add WIP transactional safe writer
...
Very much incomplete, in the process of being adapted from the one I
already wrote for glide.
2017-01-04 17:19:32 -08:00
sam boyer
082fe0003c
Add locksAreEquivalent()
...
Simple helper func to see if two *lock instances are equivalent - same
memo, same projects.
2017-01-04 17:19:32 -08:00
Jess Frazelle
921671739b
compare version strings against network fetched version
...
Signed-off-by: Jess Frazelle <acidburn@google.com>
2017-01-04 16:18:36 -08:00
Jess Frazelle
685d5fc0f0
better wording of errors
...
fix nil being passed to errors.Wrap()
Signed-off-by: Jess Frazelle <acidburn@google.com>
2017-01-04 16:18:36 -08:00
sam boyer
5b2ff11262
chasing gps: s/NetworkName/Source/
2017-01-04 13:07:28 -08:00
sam boyer
96ea714ac2
Chase latest gps master
2017-01-04 13:07:28 -08:00
Jess Frazelle
e955d434e4
fix tests
...
Signed-off-by: Jess Frazelle <acidburn@google.com>
2017-01-04 11:25:12 -08:00
sam boyer
3e21bee49f
Tweak my text changes just a little bit more
2017-01-04 11:32:47 -05:00
Peter Bourgon
7686693e43
Further review feedback re: overrides
2017-01-04 11:32:47 -05:00
Peter Bourgon
3d96894df5
Further review feedback
2017-01-04 11:32:47 -05:00
Peter Bourgon
f7f4d7d481
Review feedback
2017-01-04 11:32:47 -05:00
Peter Bourgon
993b0cfb53
Update column descriptions in status after clarification
2017-01-04 11:32:47 -05:00
Peter Bourgon
f667091a4f
One clarification to init's short help
2017-01-04 11:32:47 -05:00
Peter Bourgon
db5c007193
Refactor command processing and help text
...
Sorry for this big change. I think it's a big improvement.
First, I restructured how commands work.
- Commands are now structs that implement the command interface
- Flags are bound to parameters in the command struct
- Run is a method on the command struct, with access to flag vars
This allowed me to make a lot of consistency improvements.
- Good news: dep foo -v ... works
- Bad news: dep -v foo ... stopped working (but that was weird)
- Good news: dep foo -h works and looks consistent
- Bad news: dep help foo doesn't exist anymore (but that was weird)
With all of that in place, I was able to audit and refactor all of the
help texts. I think they're a lot better. The biggest individual change
was that I moved all of the ensure usage examples to a special flag,
ensure -examples. I hope that's acceptable.
If I screwed anything else up, please accept my apologies.
2017-01-04 11:32:47 -05:00
Peter Bourgon
4327a2c2c3
First pass at normalizing help texts
...
- short/long should not embed leading/trailing newlines
- Normalize grammar in short texts, and remove trailing periods
- Remove tabs from strings that will be printed to terminal
- Use tabwriter to print table of subcommands
2017-01-04 11:32:47 -05:00
sam boyer
1eed2b857c
ensure: fix panic on empty constraint
2017-01-03 16:53:45 -08:00
Peter Bourgon
a00070b222
status: CAPITALIZE table headers
...
Also, use ISO-9601-certified 2-space padding.
Closes #68 .
2016-12-30 09:23:14 -05:00
sam boyer
af226cb140
ensure: only trace if verbose flag is set
2016-12-28 22:25:20 -05:00
Jess Frazelle
3c40822336
add tests for DeriveManifestAndLock
...
Signed-off-by: Jess Frazelle <acidburn@google.com>
2016-12-22 12:44:47 -05:00
Jess Frazelle
99f23e372e
change os.Rename to copyFile for cross-device err
...
Signed-off-by: Jess Frazelle <acidburn@google.com>
2016-12-19 16:33:34 -08:00
Edward Muller
83e2ed52be
change project data function to return a struct
...
Signed-off-by: Jess Frazelle <acidburn@google.com>
2016-12-19 16:26:18 -08:00
Jess Frazelle
6f2a43eb66
start of remove and move some internals of init to seperate function
...
Signed-off-by: Jess Frazelle <acidburn@google.com>
do not send in manifest
Signed-off-by: Jess Frazelle <acidburn@google.com>
setup logging
Signed-off-by: Jess Frazelle <acidburn@google.com>
2016-12-19 16:26:18 -08:00
Jess Frazelle
d4783353bc
fix vet
...
Signed-off-by: Jess Frazelle <acidburn@google.com>
2016-12-19 11:50:52 -08:00
Jess Frazelle
d7729dffc8
fix test memo
...
Signed-off-by: Jess Frazelle <acidburn@google.com>
2016-12-19 11:33:29 -08:00
sam boyer
cf58a097e1
dep: update gps to v0.13.1
...
This fixes the semver 2.x uint incompatibility issue.
2016-12-19 11:22:45 -08:00
sam boyer
2494a060b5
dep: implement Required pkgs in manifest
2016-12-19 11:22:45 -08:00
sam boyer
06af1bbffb
dep: Update gps to v0.13.0; semver to latest 2.x
...
Includes small changes required to compile; follow-up commit will flesh
out the Required implementation on manifest.
2016-12-19 11:22:45 -08:00
Jess Frazelle
0687487f02
fix panic when running dep -v
...
Signed-off-by: Jess Frazelle <acidburn@google.com>
2016-12-16 22:22:15 -05:00
Jess Frazelle
3b5eeb2373
fix where bzr was assumed to be hex
...
Signed-off-by: Jess Frazelle <acidburn@google.com>
2016-12-16 22:20:43 -05:00
Jess Frazelle
1c04b49e64
add comments and cleanup tests
...
Signed-off-by: Jess Frazelle <acidburn@google.com>
2016-12-16 22:20:43 -05:00
Jess Frazelle
d9f842408b
add tests for isDir and isRegular
...
Signed-off-by: Jess Frazelle <acidburn@google.com>
2016-12-16 22:20:43 -05:00
Jess Frazelle
5eb896fe4f
add more tests for context.
...
Signed-off-by: Jess Frazelle <acidburn@google.com>
2016-12-16 22:20:43 -05:00
Jess Frazelle
07c6fd6bf2
add tests for deduceConstraint
...
Signed-off-by: Jess Frazelle <acidburn@google.com>
2016-12-16 22:20:43 -05:00
Jess Frazelle
fc2f693bec
add tests for copyFile and copyFolder
...
Signed-off-by: Jess Frazelle <acidburn@google.com>
2016-12-16 22:20:43 -05:00
Jess Frazelle
e3760cddfb
tests: fix where repos depend on knowing master lastest sha
...
Signed-off-by: Jess Frazelle <acidburn@google.com>
2016-12-16 16:06:12 -08:00
Andrew Gerrand
6fb1597cb4
status: fix analysis of latest revision
...
Show newer revisions for branch constraints.
Also fix formatting when no latest version available.
2016-12-15 10:45:18 -08:00
Andrew Gerrand
821c8de062
Add verbose logging flag, fix init for projects with packages
2016-12-15 11:05:52 +11:00
sam boyer
fbc9cf08c1
ensure: add tests for ensure
2016-12-13 19:10:00 -05:00
Jess Frazelle
aaa7244e32
ensure: change overrides flag to stringSlice
...
Signed-off-by: Jess Frazelle <acidburn@google.com>
2016-12-13 19:10:00 -05:00
sam boyer
c4e49d1148
ensure: use override flag when modding manifest
2016-12-13 19:10:00 -05:00
sam boyer
2707de62b6
dep: make subcommand flags work
2016-12-13 19:10:00 -05:00
sam boyer
dabbc45c45
ensure: remove debug output
2016-12-13 19:10:00 -05:00
Edward Muller
5b3352dc16
dep: Use the returned solution for the lock
...
Instead of trying to be fancy about things, just use the returned
solution data for the lock
2016-12-12 12:09:37 -08:00
Edward Muller
ae092cdbb5
dep: ensure we don't use existing locked version
...
If we are downgrading an existing dep then remove it from the lock
before solving.
2016-12-12 12:09:37 -08:00
Edward Muller
0a3ab89577
dep: Results from a `./dep ensure` run
...
BOOM!
2016-12-12 12:09:37 -08:00
Edward Muller
ecba9a27ff
dep: init and save the resulting manfest/lock now
2016-12-12 12:09:37 -08:00
Edward Muller
42acc8d2e2
dep: write updated manfiest, lock and vendor after ensure
2016-12-12 12:09:37 -08:00
Edward Muller
f0cf9134fc
dep: Print help
2016-12-09 10:15:11 -08:00
Jess Frazelle
0378053f0a
Add initial constraint parsing for ensure
...
Signed-off-by: Jess Frazelle <acidburn@google.com>
2016-12-09 10:02:31 -08:00