Local Workspaces Permissions Management and GitHub Integration
up vote
0
down vote
favorite
I have a folder ~/workspaces where I place all my local repositories from GitHub and other coding projects.
I use VS Code and have had permissions problems since I installed Ubuntu a month ago. I receive the EACCES: permission denied
in VS Code when I try to save files every single time after I did a git checkout branch
. Is this normal?
I counter it with $ sudo chown -R <user-name> <directory-name>
and sudo chmod -R 777 .
(I do not really know whats the difference anyway) but it keeps coming up again.
Also, I thought doing sudo npm i
is a bad thing but I keep getting Access Denied Errors
for both local and global installations with npm if I do not sudo. How can I prevent this?
Finally, I would love to automatically login with GitHub via console without the need to constantly login with username and password. A quick Google could not find me a solution. How can I integrate an Access Token for the whole workspace folder (all repositories)? Is this possible?
Thank you very much for your support, it is much appreciated!
I am on Ubuntu 18.04.1 LTS btw.
permissions sudo git npm visual-studio-code
add a comment |
up vote
0
down vote
favorite
I have a folder ~/workspaces where I place all my local repositories from GitHub and other coding projects.
I use VS Code and have had permissions problems since I installed Ubuntu a month ago. I receive the EACCES: permission denied
in VS Code when I try to save files every single time after I did a git checkout branch
. Is this normal?
I counter it with $ sudo chown -R <user-name> <directory-name>
and sudo chmod -R 777 .
(I do not really know whats the difference anyway) but it keeps coming up again.
Also, I thought doing sudo npm i
is a bad thing but I keep getting Access Denied Errors
for both local and global installations with npm if I do not sudo. How can I prevent this?
Finally, I would love to automatically login with GitHub via console without the need to constantly login with username and password. A quick Google could not find me a solution. How can I integrate an Access Token for the whole workspace folder (all repositories)? Is this possible?
Thank you very much for your support, it is much appreciated!
I am on Ubuntu 18.04.1 LTS btw.
permissions sudo git npm visual-studio-code
1
who owns~/workspaces
(ls -l ~/workspaces
), how do you launch vscode. And password aging can be used to prevent constant logins.
– George Udosen
Nov 17 at 13:30
1
it's keep coming up because you keep writing to that location as root... which should be.
– George Udosen
Nov 17 at 13:46
add a comment |
up vote
0
down vote
favorite
up vote
0
down vote
favorite
I have a folder ~/workspaces where I place all my local repositories from GitHub and other coding projects.
I use VS Code and have had permissions problems since I installed Ubuntu a month ago. I receive the EACCES: permission denied
in VS Code when I try to save files every single time after I did a git checkout branch
. Is this normal?
I counter it with $ sudo chown -R <user-name> <directory-name>
and sudo chmod -R 777 .
(I do not really know whats the difference anyway) but it keeps coming up again.
Also, I thought doing sudo npm i
is a bad thing but I keep getting Access Denied Errors
for both local and global installations with npm if I do not sudo. How can I prevent this?
Finally, I would love to automatically login with GitHub via console without the need to constantly login with username and password. A quick Google could not find me a solution. How can I integrate an Access Token for the whole workspace folder (all repositories)? Is this possible?
Thank you very much for your support, it is much appreciated!
I am on Ubuntu 18.04.1 LTS btw.
permissions sudo git npm visual-studio-code
I have a folder ~/workspaces where I place all my local repositories from GitHub and other coding projects.
I use VS Code and have had permissions problems since I installed Ubuntu a month ago. I receive the EACCES: permission denied
in VS Code when I try to save files every single time after I did a git checkout branch
. Is this normal?
I counter it with $ sudo chown -R <user-name> <directory-name>
and sudo chmod -R 777 .
(I do not really know whats the difference anyway) but it keeps coming up again.
Also, I thought doing sudo npm i
is a bad thing but I keep getting Access Denied Errors
for both local and global installations with npm if I do not sudo. How can I prevent this?
Finally, I would love to automatically login with GitHub via console without the need to constantly login with username and password. A quick Google could not find me a solution. How can I integrate an Access Token for the whole workspace folder (all repositories)? Is this possible?
Thank you very much for your support, it is much appreciated!
I am on Ubuntu 18.04.1 LTS btw.
permissions sudo git npm visual-studio-code
permissions sudo git npm visual-studio-code
asked Nov 17 at 11:31
Andre
378
378
1
who owns~/workspaces
(ls -l ~/workspaces
), how do you launch vscode. And password aging can be used to prevent constant logins.
– George Udosen
Nov 17 at 13:30
1
it's keep coming up because you keep writing to that location as root... which should be.
– George Udosen
Nov 17 at 13:46
add a comment |
1
who owns~/workspaces
(ls -l ~/workspaces
), how do you launch vscode. And password aging can be used to prevent constant logins.
– George Udosen
Nov 17 at 13:30
1
it's keep coming up because you keep writing to that location as root... which should be.
– George Udosen
Nov 17 at 13:46
1
1
who owns
~/workspaces
(ls -l ~/workspaces
), how do you launch vscode. And password aging can be used to prevent constant logins.– George Udosen
Nov 17 at 13:30
who owns
~/workspaces
(ls -l ~/workspaces
), how do you launch vscode. And password aging can be used to prevent constant logins.– George Udosen
Nov 17 at 13:30
1
1
it's keep coming up because you keep writing to that location as root... which should be.
– George Udosen
Nov 17 at 13:46
it's keep coming up because you keep writing to that location as root... which should be.
– George Udosen
Nov 17 at 13:46
add a comment |
1 Answer
1
active
oldest
votes
up vote
1
down vote
accepted
Turn on the credential helper so that Git will save your password in memory for some time. By default, Git will cache your password for 15 minutes.
git config --global credential.helper cache
# Set git to use the credential memory cache
git config --global credential.helper 'cache --timeout=3600'
# Set the cache to timeout after 1 hour (setting is in seconds)
See: https://help.github.com/articles/caching-your-github-password-in-git/
add a comment |
1 Answer
1
active
oldest
votes
1 Answer
1
active
oldest
votes
active
oldest
votes
active
oldest
votes
up vote
1
down vote
accepted
Turn on the credential helper so that Git will save your password in memory for some time. By default, Git will cache your password for 15 minutes.
git config --global credential.helper cache
# Set git to use the credential memory cache
git config --global credential.helper 'cache --timeout=3600'
# Set the cache to timeout after 1 hour (setting is in seconds)
See: https://help.github.com/articles/caching-your-github-password-in-git/
add a comment |
up vote
1
down vote
accepted
Turn on the credential helper so that Git will save your password in memory for some time. By default, Git will cache your password for 15 minutes.
git config --global credential.helper cache
# Set git to use the credential memory cache
git config --global credential.helper 'cache --timeout=3600'
# Set the cache to timeout after 1 hour (setting is in seconds)
See: https://help.github.com/articles/caching-your-github-password-in-git/
add a comment |
up vote
1
down vote
accepted
up vote
1
down vote
accepted
Turn on the credential helper so that Git will save your password in memory for some time. By default, Git will cache your password for 15 minutes.
git config --global credential.helper cache
# Set git to use the credential memory cache
git config --global credential.helper 'cache --timeout=3600'
# Set the cache to timeout after 1 hour (setting is in seconds)
See: https://help.github.com/articles/caching-your-github-password-in-git/
Turn on the credential helper so that Git will save your password in memory for some time. By default, Git will cache your password for 15 minutes.
git config --global credential.helper cache
# Set git to use the credential memory cache
git config --global credential.helper 'cache --timeout=3600'
# Set the cache to timeout after 1 hour (setting is in seconds)
See: https://help.github.com/articles/caching-your-github-password-in-git/
edited Nov 17 at 13:41
answered Nov 17 at 13:11
George Udosen
18.3k94065
18.3k94065
add a comment |
add a comment |
Sign up or log in
StackExchange.ready(function () {
StackExchange.helpers.onClickDraftSave('#login-link');
});
Sign up using Google
Sign up using Facebook
Sign up using Email and Password
Post as a guest
Required, but never shown
StackExchange.ready(
function () {
StackExchange.openid.initPostLogin('.new-post-login', 'https%3a%2f%2faskubuntu.com%2fquestions%2f1093701%2flocal-workspaces-permissions-management-and-github-integration%23new-answer', 'question_page');
}
);
Post as a guest
Required, but never shown
Sign up or log in
StackExchange.ready(function () {
StackExchange.helpers.onClickDraftSave('#login-link');
});
Sign up using Google
Sign up using Facebook
Sign up using Email and Password
Post as a guest
Required, but never shown
Sign up or log in
StackExchange.ready(function () {
StackExchange.helpers.onClickDraftSave('#login-link');
});
Sign up using Google
Sign up using Facebook
Sign up using Email and Password
Post as a guest
Required, but never shown
Sign up or log in
StackExchange.ready(function () {
StackExchange.helpers.onClickDraftSave('#login-link');
});
Sign up using Google
Sign up using Facebook
Sign up using Email and Password
Sign up using Google
Sign up using Facebook
Sign up using Email and Password
Post as a guest
Required, but never shown
Required, but never shown
Required, but never shown
Required, but never shown
Required, but never shown
Required, but never shown
Required, but never shown
Required, but never shown
Required, but never shown
1
who owns
~/workspaces
(ls -l ~/workspaces
), how do you launch vscode. And password aging can be used to prevent constant logins.– George Udosen
Nov 17 at 13:30
1
it's keep coming up because you keep writing to that location as root... which should be.
– George Udosen
Nov 17 at 13:46