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

--rcfile ....... sudorc': No such file or directory #42

Open
fjqingyou opened this issue Jun 14, 2020 · 3 comments
Open

--rcfile ....... sudorc': No such file or directory #42

fjqingyou opened this issue Jun 14, 2020 · 3 comments

Comments

@fjqingyou
Copy link

There is a problem with the installation. Can't solve it by me, please help me

Administrator@WIN-S09457ODR3H MINGW64 /e/SoftEdit/git
$ curl -s https://raw.githubusercontent.com/imachug/win-sudo/master/install.sh | sh

Administrator@WIN-S09457ODR3H MINGW64 /e/SoftEdit/git
$ su
bash: su: command not found

Administrator@WIN-S09457ODR3H MINGW64 /e/SoftEdit/git
$ sudo
bash: sudo: command not found

Administrator@WIN-S09457ODR3H MINGW64 /e/SoftEdit/git
$ git clone git@github.com:imachug/win-sudo.git
Cloning into 'win-sudo'...
remote: Enumerating objects: 22, done.
remote: Counting objects: 100% (22/22), done.
remote: Compressing objects: 100% (22/22), done.
remote: Total 308 (delta 11), reused 1 (delta 0), pack-reused 286
Receiving objects: 100% (308/308), 3.32 MiB | 1.96 MiB/s, done.
Resolving deltas: 100% (146/146), done.

Administrator@WIN-S09457ODR3H MINGW64 /e/SoftEdit/git
$ cd win-sudo/

Administrator@WIN-S09457ODR3H MINGW64 /e/SoftEdit/git/win-sudo (master)
$ install.sh
bash: install.sh: command not found

Administrator@WIN-S09457ODR3H MINGW64 /e/SoftEdit/git/win-sudo (master)
$ ls
img/ install.sh* LICENSE README.md s/

Administrator@WIN-S09457ODR3H MINGW64 /e/SoftEdit/git/win-sudo (master)
$ ./install.sh
Downloading win-sudo...
mkdir: created directory '/c/Users/Administrator/bin'
mkdir: created directory '/c/Users/Administrator/bin/win-sudo'
Processing /c/Users/Administrator/.bashrc
Appending sudo initialization to /c/Users/Administrator/.bashrc
Win-sudo successfully installed!

Administrator@WIN-S09457ODR3H MINGW64 ~/bin/win-sudo (master)
$ su
/c/Users/Administrator/bin/win-sudo/s/sudo: line 31: /c/Users/Administrator/bin/win-sudo/'/usr/bin/bash' '--rcfile' '/c/Users/Administrator/bin/win-sudo/s/sudorc': No such file or directory

Administrator@WIN-S09457ODR3H MINGW64 ~/bin/win-sudo (master)
$ cd /e/SoftEdit/git/win-sudo

Administrator@WIN-S09457ODR3H MINGW64 /e/SoftEdit/git/win-sudo (master)
$ ./install.sh
Downloading win-sudo...
Cleaning ~/bin/win-sudo...
removed '/c/Users/Administrator/bin/win-sudo/.git/config'
removed '/c/Users/Administrator/bin/win-sudo/.git/description'
removed '/c/Users/Administrator/bin/win-sudo/.git/FETCH_HEAD'
removed '/c/Users/Administrator/bin/win-sudo/.git/HEAD'
removed '/c/Users/Administrator/bin/win-sudo/.git/hooks/applypatch-msg.sample'
removed '/c/Users/Administrator/bin/win-sudo/.git/hooks/commit-msg.sample'
removed '/c/Users/Administrator/bin/win-sudo/.git/hooks/fsmonitor-watchman.sample'
removed '/c/Users/Administrator/bin/win-sudo/.git/hooks/post-update.sample'
removed '/c/Users/Administrator/bin/win-sudo/.git/hooks/pre-applypatch.sample'
removed '/c/Users/Administrator/bin/win-sudo/.git/hooks/pre-commit.sample'
removed '/c/Users/Administrator/bin/win-sudo/.git/hooks/pre-merge-commit.sample'
removed '/c/Users/Administrator/bin/win-sudo/.git/hooks/pre-push.sample'
removed '/c/Users/Administrator/bin/win-sudo/.git/hooks/pre-rebase.sample'
removed '/c/Users/Administrator/bin/win-sudo/.git/hooks/pre-receive.sample'
removed '/c/Users/Administrator/bin/win-sudo/.git/hooks/prepare-commit-msg.sample'
removed '/c/Users/Administrator/bin/win-sudo/.git/hooks/update.sample'
removed directory '/c/Users/Administrator/bin/win-sudo/.git/hooks'
removed '/c/Users/Administrator/bin/win-sudo/.git/index'
removed '/c/Users/Administrator/bin/win-sudo/.git/info/exclude'
removed '/c/Users/Administrator/bin/win-sudo/.git/info/sparse-checkout'
removed directory '/c/Users/Administrator/bin/win-sudo/.git/info'
removed '/c/Users/Administrator/bin/win-sudo/.git/logs/HEAD'
removed '/c/Users/Administrator/bin/win-sudo/.git/logs/refs/heads/master'
removed directory '/c/Users/Administrator/bin/win-sudo/.git/logs/refs/heads'
removed '/c/Users/Administrator/bin/win-sudo/.git/logs/refs/remotes/base/master'
removed directory '/c/Users/Administrator/bin/win-sudo/.git/logs/refs/remotes/base'
removed directory '/c/Users/Administrator/bin/win-sudo/.git/logs/refs/remotes'
removed directory '/c/Users/Administrator/bin/win-sudo/.git/logs/refs'
removed directory '/c/Users/Administrator/bin/win-sudo/.git/logs'
removed directory '/c/Users/Administrator/bin/win-sudo/.git/objects/info'
removed '/c/Users/Administrator/bin/win-sudo/.git/objects/pack/pack-28e48dac32b590110aefc8705e171164b4c41779.idx'
removed '/c/Users/Administrator/bin/win-sudo/.git/objects/pack/pack-28e48dac32b590110aefc8705e171164b4c41779.pack'
removed directory '/c/Users/Administrator/bin/win-sudo/.git/objects/pack'
removed directory '/c/Users/Administrator/bin/win-sudo/.git/objects'
removed '/c/Users/Administrator/bin/win-sudo/.git/refs/heads/master'
removed directory '/c/Users/Administrator/bin/win-sudo/.git/refs/heads'
removed '/c/Users/Administrator/bin/win-sudo/.git/refs/remotes/base/HEAD'
removed '/c/Users/Administrator/bin/win-sudo/.git/refs/remotes/base/master'
removed directory '/c/Users/Administrator/bin/win-sudo/.git/refs/remotes/base'
removed directory '/c/Users/Administrator/bin/win-sudo/.git/refs/remotes'
removed directory '/c/Users/Administrator/bin/win-sudo/.git/refs/tags'
removed directory '/c/Users/Administrator/bin/win-sudo/.git/refs'
removed directory '/c/Users/Administrator/bin/win-sudo/.git'
removed '/c/Users/Administrator/bin/win-sudo/s/aliases'
removed '/c/Users/Administrator/bin/win-sudo/s/path.sh'
removed '/c/Users/Administrator/bin/win-sudo/s/su'
removed '/c/Users/Administrator/bin/win-sudo/s/sudo'
removed '/c/Users/Administrator/bin/win-sudo/s/sudobackend'
removed '/c/Users/Administrator/bin/win-sudo/s/sudorc'
rm: cannot remove '/c/Users/Administrator/bin/win-sudo/s': Device or resource busy
./install.sh: error trap: line 10: syntax error near unexpected token (' ./install.sh: error trap: line 10: echo Failed to install, sorry :(; exit 1'
Processing /c/Users/Administrator/.bashrc
Sudo initialization already in file /c/Users/Administrator/.bashrc
Win-sudo successfully installed!

Administrator@WIN-S09457ODR3H MINGW64 ~/bin/win-sudo (master)
$ su
/c/Users/Administrator/bin/win-sudo/s/sudo: line 31: /c/Users/Administrator/bin/win-sudo/'/usr/bin/bash' '--rcfile' '/c/Users/Administrator/bin/win-sudo/s/sudorc': No such file or directory

@fjqingyou
Copy link
Author

find a gif,but
$ py -3 -m pip install asciinema
bash: py: command not found

@bizxta
Copy link
Contributor

bizxta commented Oct 15, 2020

This application doesn't have su. It only also sudo. Run your commands with sudo echo "nobody expects the Spanish inquisition!"

Never mind, it does provide su!

@bizxta
Copy link
Contributor

bizxta commented Oct 15, 2020

Looks to me like when you install it, you need to restart your command prompt so it reads the updated bashrc code. I think it adds the directory for the binaries into your PATH.

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

No branches or pull requests

2 participants