Added 'create' and '--export SHELL' to the cli#270
Added 'create' and '--export SHELL' to the cli#270jadutter wants to merge 0 commit intotheskumar:masterfrom
Conversation
jadutter
commented
Aug 5, 2020
- Added support for specifying when to add 'export' to the dot file
- Added support for creating dot files from the cli
|
...I'm not sure what else I need to do to help contribute... |
|
Thank you for submitting this pull request. I like the idea of being able to make
So what about just adding a bare About the |
|
I tried creating the file through set and it didn't work for me. I only added the create since it seemed weird that I there wasn't a means in the cli to do it. Probably just user error, but I'll double check. Extension checking only matters if other shells matter, and I was uncertain how many people use it in other shells where export wasn't valid. I started to add batch (Windows) as a shell option, but the parser failed to read it, and I decided to keep it small and see what other people thought. |
|
Hi @jadutter , thanks for sending the PR! The That said, the project has evolved and I would prefer to have I'm also little concerned around the use-case vs the technical debt this project is going take because of adding export feature for each type of shell. |
I'm not attached to the idea of different shells. I'm just trying to help make it useful to as many people as possible. Shall I:
|
|
I think that would be great. |
|
I believe I've made the necessary changes. Please let me know if there's any other changes I can make. |
bbc2
left a comment
There was a problem hiding this comment.
Looks good overall! Just a few minor comments.
Could you add a simple test case for something simple like set --export a b that checks that the env file then contains export a=b? It might make Coveralls happy but don't worry if it doesn't.
Also, it looks like the CI doesn't run linters and tests anymore (@theskumar any idea why that could be? I don't see Python-dotenv in Travis CI anymore). Could you try running flake8 or tox -e lint locally to check for warnings?
|
Let me know if I should change it so that it does not automatically add the file extension. |
Yes please. I would rather have the user include the extension themselves if they want it. |
|
I reverted the test, updated the changelog, and squashed the commits. Unfortunately, I pushed the wrong commit to your branch, which closed the PR and prevented me from pushing anything else to it. That's the second time this happens to me; apparently I can't get it right. Anyway, I created a new PR (#275) with that commit and merged it. Thank you for your contribution! I'll release a new version after I have figured out what's wrong with Travis CI. |