Skip to content

cat heredoc will not work with sudo #418

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

Merged
merged 1 commit into from
May 13, 2022

Conversation

wanderxjtu
Copy link
Contributor

sudo cat > SOMEPATH <<EOF won't work when user has no permission to write to SOMEPATH.
Using sudo tee SOMEPATH instead.

Copy link
Member

@bergwolf bergwolf left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Thanks!

@bergwolf
Copy link
Member

Thanks @wanderxjtu!

It is a good practice to add a subsystem prefix to the commit message title and a few words to better describe it. So something like this would look better:

docs: fix cat script example

sudo cat > SOMEPATH <<EOF won't work when user has no permission to write to SOMEPATH.
Using sudo tee SOMEPATH instead.

Signed-off-by wanderxjtu <[email protected]>

`sudo cat > SOMEPATH <<EOF` won't work when user has no permission to
write to SOMEPATH.
Using `sudo tee SOMEPATH` instead.

Signed-off-by: wanderxjtu <[email protected]>
@wanderxjtu
Copy link
Contributor Author

@bergwolf commit message updated, thx.

@bergwolf
Copy link
Member

@wanderxjtu Thanks a lot!

@bergwolf bergwolf merged commit 3ef083a into dragonflyoss:master May 13, 2022
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

Successfully merging this pull request may close these issues.

2 participants