Closed
Bug 635169
Opened 13 years ago
Closed 13 years ago
cfx init should ignore hidden folders
Categories
(Add-on SDK Graveyard :: General, defect)
Add-on SDK Graveyard
General
Tracking
(Not tracked)
RESOLVED
FIXED
People
(Reporter: KWierso, Assigned: warner)
References
Details
Attachments
(1 file)
2.07 KB,
patch
|
irakli
:
review+
|
Details | Diff | Splinter Review |
A user on IRC was getting ready to set up a package in the local SDK. He ran bin\activate, and made a folder for his package, then changed to that directory and ran "cfx init". It then complained about it not being an empty directory. After creating the folder, the user had added it to a Subversion repository, so it had a ".svn" folder in it prior to running "cfx init". If ignoring hidden folders is too much to do, maybe just whitelist folders like ".svn", ".hg" (and whatever git uses)?
Assignee | ||
Comment 1•13 years ago
|
||
sounds like a good idea to me. Probably just ignore /^\./ -matching items. The change will go into python-lib/cuddlefish/__init__.py in the "initializer()" function, something like: existing = [fn for fn in os.listdir(path) if not fn.startswith(".")] if existing: print >>err, 'This command must be run in an empty directory.' return 1
Assignee | ||
Comment 2•13 years ago
|
||
this patch should fix the problem, however let's keep bug 613604 (cfx init newdir) in mind as the preferred way to avoid this sort of thing
Assignee: nobody → warner-bugzilla
Comment 3•13 years ago
|
||
Tested the patch. Works for me. Thanks Brian!
Comment 5•13 years ago
|
||
Someone else fixed a special case of this with pull request 132 <https://github.com/mozilla/addon-sdk/pull/132>. Brian: any reason not to get review on your patch at this point?
OS: Windows 7 → All
Hardware: x86 → All
Assignee | ||
Comment 6•13 years ago
|
||
nope, if it worked for Mihai, let's r? it.
Assignee | ||
Comment 7•13 years ago
|
||
Comment on attachment 514209 [details] [diff] [review] patch, with tests Irakli, want to take a look at this?
Attachment #514209 -
Flags: review?(rFobic)
Comment 8•13 years ago
|
||
Comment on attachment 514209 [details] [diff] [review] patch, with tests Looks good ;)
Attachment #514209 -
Flags: review+
Comment 11•13 years ago
|
||
(In reply to comment #10) > Landed Can you provide a link to the changeset?
Keywords: checkin-needed
Reporter | ||
Comment 12•13 years ago
|
||
https://github.com/mozilla/addon-sdk/commit/80b97b6b8e40e3bf8418247c6626c6b25058ce6a
Updated•13 years ago
|
Attachment #514209 -
Flags: review?(rFobic)
You need to log in
before you can comment on or make changes to this bug.
Description
•