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

feat: add shellharden #14

Merged
merged 1 commit into from
Aug 30, 2023
Merged

Conversation

WhoIsSethDaniel
Copy link
Contributor

No description provided.

@stevearc
Copy link
Owner

Thanks!

@stevearc stevearc merged commit 863fb46 into stevearc:master Aug 30, 2023
7 checks passed
@WhoIsSethDaniel
Copy link
Contributor Author

This isn't actually working, but I need some advice. The correct command to have shellharden do its job is:

cat <file> | shellharden --transform ''

Note the two quotes at the end. The result is a corrected shell file sent to stdout.

However, I can't get the two quotes to execute properly. The log has this:

[INFO] Run shellharden on /home/seth/.bash-init/vi.sh
[DEBUG] Run command: { "shellharden", "--transform", "''" }
[ERROR] shellharden exited with code 1
[WARN] shellharden stdout: { "" }
[WARN] shellharden stderr: { "'': No such file or directory (os error 2)", "" }
[ERROR] Formatter 'shellharden' error: '': No such file or directory (os error 2)

@WhoIsSethDaniel
Copy link
Contributor Author

Ooh. Sorry. I should have submitted this as a draft. Please see the previous comment.

@stevearc
Copy link
Owner

I believe what you would want then is

args = { "--transform", "" },

Can you give that a try and see if it works?

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