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

Simplified clear screen command #1148

Open
wants to merge 2 commits into
base: main
Choose a base branch
from
Open

Simplified clear screen command #1148

wants to merge 2 commits into from

Conversation

hugsy
Copy link
Owner

@hugsy hugsy commented Oct 30, 2024

Description

Add a new GEF config item

───────────────────────────────────── GEF configuration setting: gef.clear_screen_command ─────────────────────────────────────
gef.clear_screen_command (str) = "clear -x"

Description:
        Command to use to clear the screen.

Fixes #1147

Checklist

  • My code follows the code style of this project.
  • My change includes a change to the documentation, if required.
  • If my change adds new code, adequate tests have been added.
  • I have read and agree to the CONTRIBUTING document.

Copy link

🤖 Coverage update for 82ae86c 🟢

Old New
Commit 5376d78 82ae86c
Score 71.2662% 71.2717% (0.0055)

Copy link

🤖 Coverage update for 82ae86c 🟢

Old New
Commit 5376d78 82ae86c
Score 71.2662% 71.2662% (0)

@hugsy hugsy self-assigned this Oct 30, 2024
@hugsy hugsy marked this pull request as ready for review October 30, 2024 17:18
@hugsy hugsy added this to the 2024.09 milestone Oct 30, 2024
@hugsy
Copy link
Owner Author

hugsy commented Oct 31, 2024

bad idea

@hugsy hugsy closed this Oct 31, 2024
@hugsy hugsy deleted the hugsy/fix-1147 branch October 31, 2024 15:39
@hugsy hugsy restored the hugsy/fix-1147 branch October 31, 2024 15:50
@hugsy hugsy reopened this Oct 31, 2024
try:
with open(tty, "wt") as f:
f.write("\x1b[H\x1b[J")
sys.stdout.write("\x1b[H\x1b[J")
Copy link
Owner Author

Choose a reason for hiding this comment

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

is tty even required 🤔 ?

Copy link

🤖 Coverage update for a9930ea 🟢

Old New
Commit 5376d78 a9930ea
Score 71.2662% 71.3369% (0.0707)

Copy link

🤖 Coverage update for a9930ea 🟢

Old New
Commit 5376d78 a9930ea
Score 71.2662% 71.2662% (0)

@hugsy hugsy changed the title allow clear screen command to be customized Simplified clear screen command Nov 1, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

[Bug] GEF runs my shell for spawning commands like clear
1 participant