Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

distribute command fails, requires --project-path #3

Open
am-play opened this issue Aug 10, 2024 · 1 comment
Open

distribute command fails, requires --project-path #3

am-play opened this issue Aug 10, 2024 · 1 comment
Assignees
Labels
enhancement New feature or request

Comments

@am-play
Copy link

am-play commented Aug 10, 2024

Problem
The distribute command fails to run independently because it requires the project path value which can only be passed to the automate command.

autosparkle distribute --env "local" --dmg-path "ci_scripts/Build/SparkleTest-1.0.0.dmg" --app-display-name "SparkleTest" --marketing-version "1.0.0" --current-project-version "1" --minimum-macos-version "13.0" --trace /opt/homebrew/lib/ruby/gems/3.3.0/gems/autosparkle-0.1.1/lib/autosparkle/environment/environment.rb:79:in load_environment': Cannot find the project directory path to load the environment variables (RuntimeError)
from /opt/homebrew/lib/ruby/gems/3.3.0/gems/autosparkle-0.1.1/lib/autosparkle/environment/environment.rb:34:in initialize' from /opt/homebrew/lib/ruby/gems/3.3.0/gems/autosparkle-0.1.1/lib/autosparkle/main.rb:116:in block (2 levels) in <top (required)>'
from /opt/homebrew/lib/ruby/gems/3.3.0/gems/commander-5.0.0/lib/commander/command.rb:187:in call' from /opt/homebrew/lib/ruby/gems/3.3.0/gems/commander-5.0.0/lib/commander/command.rb:157:in run'
from /opt/homebrew/lib/ruby/gems/3.3.0/gems/commander-5.0.0/lib/commander/runner.rb:444:in run_active_command' from /opt/homebrew/lib/ruby/gems/3.3.0/gems/commander-5.0.0/lib/commander/runner.rb:58:in run!'
from /opt/homebrew/lib/ruby/gems/3.3.0/gems/commander-5.0.0/lib/commander/delegates.rb:18:in run!' from /opt/homebrew/lib/ruby/gems/3.3.0/gems/commander-5.0.0/lib/commander/import.rb:7:in block in <top (required)>'
autosparkle distribute --env "local" --project-path ./SparkleTest.xcodeproj/ --dmg-path "ci_scripts/Build/SparkleTest-1.0.0.dmg" --app-display-name "SparkleTest" --marketing-version "1.0.0" --current-project-version "1" --minimum-macos-version "13.0" --trace
/opt/homebrew/lib/ruby/gems/3.3.0/gems/commander-5.0.0/lib/commander/command.rb:172:in parse_options_and_call_procs': invalid option: --project-path (OptionParser::InvalidOption) from /opt/homebrew/lib/ruby/gems/3.3.0/gems/commander-5.0.0/lib/commander/command.rb:157:in run'
from /opt/homebrew/lib/ruby/gems/3.3.0/gems/commander-5.0.0/lib/commander/runner.rb:444:in run_active_command' from /opt/homebrew/lib/ruby/gems/3.3.0/gems/commander-5.0.0/lib/commander/runner.rb:58:in run!'
from /opt/homebrew/lib/ruby/gems/3.3.0/gems/commander-5.0.0/lib/commander/delegates.rb:18:in run!' from /opt/homebrew/lib/ruby/gems/3.3.0/gems/commander-5.0.0/lib/commander/import.rb:7:in block in <top (required)>'`

Describe the solution you'd like

Seems like the distribute command should be able to accept this param, or it should be added as an env String.

Thanks!

Andrew

@am-play am-play added the enhancement New feature or request label Aug 10, 2024
@am-play am-play changed the title [FEATURE] distribute command fails, requires --project-path Aug 10, 2024
@hadiidbouk
Copy link
Owner

Hey @am-play

Thank you for using Autosparkle!

Since the distribute command works independently, we cannot assume that there is a project directory that exists to read the environment file from it. That means we cannot pass the environment name, instead we should pass the environment file path.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
enhancement New feature or request
Projects
None yet
Development

No branches or pull requests

2 participants