TheFox / flickr-cli

A command-line interface to Flickr. Upload and download photos, photo sets, directories via shell.
https://fox21.at
25 stars 9 forks source link

Make config file option optional, and make its help text more informative #31

Closed samwilson closed 6 years ago

samwilson commented 6 years ago

It wasn't possible to not pass the config file name (-c).

TheFox commented 6 years ago

For which command was is not possible to not set it? Beside Auth you always have to use a configuration file. Otherwise this command will not work.

samwilson commented 6 years ago

Sorry, I should have been clearer...

I thought it was meant to be that if no -c was provided (or no env var set) then it'd use config.yml in the current directory. This wasn't working for me, e.g.

$ ./bin/flickr-cli auth

In FlickrCliCommand.php line 241:

  No config file path found.  

auth [-c|--config [CONFIG]] [-f|--force]

Which should either work, or the -c option should become mandatory.

I think! :) Sorry if I'm misunderstanding something.

TheFox commented 6 years ago

No, this is fine. I think it's my fault because the Docker environment always has the FLICKRCLI_CONFIG environment variable set. I guess because of this I wrote the PHP like this. Inside Docker it's totally fine to always have the environment variable set, but then you have a problem on a non-Docker environment.

Let me check the details.

TheFox commented 6 years ago

Please be aware of running composer update. I fixed some things in 0a3006f285a1342aa6a7c0bde9682872c583d861 and 1ea7c69affe2b0cd9972f61400844a6ee3022e97.