Open/add local repo from command line should not prompt for approval
See original GitHub issueDescription
If I’m adding a repo from the command line, the path is most likely correct and I have already made my decision to add it. I do not want to have to confirm a dialog box.
This would also help with automation
Version
- GitHub Desktop: 1.1.0
- Operating system: macOS 10.13.3
Steps to Reproduce
github open “/users/matt/projects/test”
Expected Behavior
Should just add it if it’s a valid local repo
Actual Behavior
I have to confirm a dialog accepting the values I know are correct because i passed them to the app
Alternatively, an add
command could be added to the github command line app.
Issue Analytics
- State:
- Created 6 years ago
- Comments:13 (11 by maintainers)
Top Results From Across the Web
Git on the command line - GitLab Docs
To execute Git commands on your computer, you must open a terminal (also known as command prompt, command shell, and command line). Here...
Read more >Adding locally hosted code to GitHub
If you have existing source code or repositories stored locally on your computer or private network you can add them to GitHub by...
Read more >Clone a Git repository | Bitbucket Cloud - Atlassian Support
Learn how to clone a Git repository using the command line, Sourcetree, or other Git clients.
Read more >Is it possible to create a remote repo on GitHub from the CLI ...
You can create a GitHub repo via the command line using the GitHub API. ... however I am not able to use the...
Read more >How to Get Started with GIT and work with GIT Remote Repo
To issue a command, start a "Terminal" (for Ubuntu/Mac) or "Git Bash" ... We do not wish to track the " .class "...
Read more >Top Related Medium Post
No results found
Top Related StackOverflow Question
No results found
Troubleshoot Live Code
Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start FreeTop Related Reddit Thread
No results found
Top Related Hackernoon Post
No results found
Top Related Tweet
No results found
Top Related Dev.to Post
No results found
Top Related Hashnode Post
No results found
Top GitHub Comments
This is what currently happens in Desktop when you provide a URL rather than a path:
I don’t think the proposed change here to add the valid repository that exists on disk changes this behaviour (which isn’t ideal).
As part of this workflow we already check if this path is associated with a tracked repository, and select that to avoid confusion:
https://github.com/desktop/desktop/blob/1b96ce51c752cc077b53a4ad01052f16ce1905b2/app/src/lib/dispatcher/dispatcher.ts#L841-L848
I think I’d be 👍 to adding the repository if:
open-repository-from-path
code path (i.e. the user initiated this from the CLI)Otherwise we should end up on this path, with details about why we need user input.
cc @desktop/core @desktop/comrades for feels