fix/style-guide-and-patches #10

Merged
taylor merged 1 commit from charlie/cvsh:fix/style-guide-and-patches into main 2026-08-04 16:29:23 +01:00
Owner

Defined MAX_PROMPT_LENGTH of 4096 for the prompt buffer and defined a skip_whitespace() helper to detect both standard and unicode non-breaking spaces as \ multi-line commands kept failing (reported bug on Discord). It now parses \\\n and \\\r and updated notify_jobs() to call rl_on_new_line() (read line on new line) prior to printing background job status.

I added a logic to cleanly strip trailing carriage returns (\r) and newlines (\n) from inputs and command capture buffers and updated the full cvsh.c to be inline with the full featured code for example char *var not char* var to match the internal style-guides in addition. Changing global variables and static tables to adopt the g_ we discussed, etc.

Lastly added die() as a helper for fatal errors or followed by exit for when something, well, dies... I did also add a .gitignore, as well.

Defined `MAX_PROMPT_LENGTH` of 4096 for the prompt buffer and defined a `skip_whitespace()` helper to detect both standard and unicode non-breaking spaces as `\` multi-line commands kept failing (_reported bug on Discord_). It now parses `\\\n` and `\\\r` and updated `notify_jobs()` to call `rl_on_new_line()` (_read line on new line_) prior to printing background job status. I added a logic to cleanly strip trailing carriage returns (`\r`) and newlines (`\n`) from inputs and command capture buffers and updated the full `cvsh.c` to be inline with the full featured code for example `char *var` not `char* var` to match the internal style-guides in addition. Changing global variables and static tables to adopt the `g_` we discussed, etc. Lastly added `die()` as a helper for fatal errors or followed by `exit` for when something, well, dies... I did also add a `.gitignore`, as well.
taylor merged commit b947e1e36f into main 2026-08-04 16:29:23 +01:00
Sign in to join this conversation.
No reviewers
vulpinelinux/Maintainers
No milestone
No project
No assignees
1 participant
Notifications
Due date
The due date is invalid or out of range. Please use the format "yyyy-mm-dd".

No due date set.

Dependencies

No dependencies set.

Reference
vulpinelinux/cvsh!10
No description provided.