Repository navigation
Chisel can build on top of already chiseled output - #25
rebornplusplus wants to merge 5 commits into
Conversation
- Records are saved at /var/lib/chisel/chisel.db - Slice names are kept in pkg_slice format one per line
* Info: In Go, os.Symlink fails if symlink already exists * Help: https://stackoverflow.com/questions/37345844/how-to-overwrite-a-symlink-in-go
|
First run: Install Second run: Install |
woky
left a comment
There was a problem hiding this comment.
Looks good. Clear and concise.
Note that there are no tests and you will probably need to address my suggestion in slices_db.go to make it testable.
* setup.Select takes new db argument now * Refactored the code fragments depending on setup.Select
|
@woky, Thanks for your suggestions! I modified the source that way and added a simple test. Can you please take a look again? |
- selection, err := setup.Select(release, test.slices)
+ selection, err := setup.Select(release, test.slices, &setup.ChiselDB{})This is very simple test. ;-) I don't think this is going to fly. Try to make a new tests with temporary directory and some existing slices installed. |
woky
left a comment
There was a problem hiding this comment.
See my take on createSymlink(): woky@d7883a0
ea88900 to
d3e6f43
Compare
|
Update:
|
| return err | ||
|
|
||
| return printVersions() | ||
| // return printVersions() |
There was a problem hiding this comment.
why has this been commented?
There was a problem hiding this comment.
It seemed like unreachable code to me, so I commented it out to keep it anyway for future reference. Doesn't make any difference if it's not commented out though.
cjdcordeiro
left a comment
There was a problem hiding this comment.
this is great. simple and functional. thanks.
I do have one comment, which is more of a request for comment (we might need to discuss it):
- the chisel DB goes into
/var/lib/chisel/chisel.db, even ifbase-fileshas not been installed. So, within the scope of #18, who owns/var/lib? In this PR you are creating it manually, but in reality it should probably belong to base-files. Should we always installbase-files_varby default? or should the chisel.db be placed in/? (or maybe we shouldn't worry about this at all...) TBD
|
@rebornplusplus I think we can close this PR, since the underlying feature will be split into multiple feature requests |
Resolves #10
Chisel records installed slices and checks before installing again
- Records are saved at /var/lib/chisel/chisel.db
- Slice names are kept in pkg_slice format one per line
Fix: Symlink overwrite
* Info: In Go, os.Symlink fails if symlink already exists
* Help: https://stackoverflow.com/questions/37345844/how-to-overwrite-a-symlink-in-go