Closed HLWeil closed 2 years ago
Thanks for this addition.
Creating a default .gitignore
appears as a good idea. However, I would not ignore files outside the standard arc folders by default. This IMHO goes against the principle of least surprise for users. E. g. extra files/dirs are in the top level are silently ignored.
As opposed to the faux readme files, could we simply add .gitkeep
files, as is customary?
@chgarth, thanks for your input 👍
Regarding .gitignore
: I see your point.. The thing is, there is actually nothing specific that has to be ignored by default. The intention with the .gitignore
was to nugde the user towards maintaining a tidy arc
by placing files in the appropriate folders.
So, I don't actually see any alternative, less harsh default .gitignore
. But alternatively, to save the user from unexpected, ignored changes, the insertion of the .gitignore
could be made optional. Maybe a --gitignore
flag could be added to the arc init
command?
Regarding .gitkeep
: I think the .gitkeep
files might cause some confusion. But the ReadMe
s could be filled with some info about the folders they are placed in. Like this, they could serve an additional purpose?
I made the .gitignore optional and replaced the Readme.md with .gitkeep files
I made the .gitignore optional and replaced the Readme.md with .gitkeep files
👍
We had earlier discussed that encouraging users to keep a "tidy" arc could be an explicit mechanism, e.g. arc sync
would state that there are files that are not annotated etc.
There are also some use cases where arcs serve a dual role (for example, if they are also RO Crates), and then additional payload (as defined in arc spec) should be expected anyway, I think.
Thanks for your efforts!
Two
git-related
features were added to support the user in creatingarcs
following the specification:91
A standard
.gitignore
file gets added to thearc
whenarc init
is called. This.gitignore
by default will makegit
only track files inside the standard arc folders.92
Dummy
ReadMe.md
files will be added toassay
subfolders (dataset
,protocols
). This will makegit
track these folders even if the user doesn't add any files themselves.