diff options
| author | Mark Levedahl <mlevedahl@gmail.com> | 2025-04-04 16:55:59 -0400 |
|---|---|---|
| committer | Taylor Blau <me@ttaylorr.com> | 2025-05-23 17:04:23 -0400 |
| commit | 2c66188b123795e4083594ee682dcf012540bee2 (patch) | |
| tree | 361826dfa75b48ca38151c15d15c8a7f09929f57 | |
| parent | git-gui: remove special treatment of Windows from open_cmd_pipe (diff) | |
| download | git-2c66188b123795e4083594ee682dcf012540bee2.tar.gz git-2c66188b123795e4083594ee682dcf012540bee2.zip | |
git-gui: remove unused proc is_shellscript
Commit 7d076d56757c (git-gui: handle shell script text filters when
loading for blame, 2011-12-09) added is_shellscript to test if a file
is executable by the shell, used only when searching for textconv
filters. The previous commit rearranged the tests for finding such
filters, and removed the only user of is_shellscript. Remove this
function.
Signed-off-by: Mark Levedahl <mlevedahl@gmail.com>
Signed-off-by: Johannes Sixt <j6t@kdbg.org>
Signed-off-by: Taylor Blau <me@ttaylorr.com>
| -rwxr-xr-x | git-gui.sh | 10 |
1 files changed, 0 insertions, 10 deletions
diff --git a/git-gui.sh b/git-gui.sh index cb0c02e5b8..72da2443e5 100755 --- a/git-gui.sh +++ b/git-gui.sh @@ -549,16 +549,6 @@ proc _git_cmd {name} { return $v } -# Test a file for a hashbang to identify executable scripts on Windows. -proc is_shellscript {filename} { - if {![file exists $filename]} {return 0} - set f [open $filename r] - fconfigure $f -encoding binary - set magic [read $f 2] - close $f - return [expr {$magic eq "#!"}] -} - # Run a shell command connected via pipes on stdout. # This is for use with textconv filters and uses sh -c "..." to allow it to # contain a command with arguments. We presume this |
