mirror of
https://github.com/fish-shell/fish-shell
synced 2024-12-25 20:33:08 +00:00
deal with Linux shebang handling
The Linux kernel only splits on the first whitespace in the shebang line (unlike BSD which splits on all whitespace). Which means there can be only one argument after the path to the program.
This commit is contained in:
parent
a5034874ab
commit
92e14d7e4a
2 changed files with 4 additions and 2 deletions
|
@ -1,4 +1,4 @@
|
||||||
#!/usr/bin/env python -B
|
#!/usr/bin/env python
|
||||||
# -*- coding: utf-8 -*-
|
# -*- coding: utf-8 -*-
|
||||||
|
|
||||||
# Run me like this: ./create_manpage_completions.py /usr/share/man/man{1,8}/* > man_completions.fish
|
# Run me like this: ./create_manpage_completions.py /usr/share/man/man{1,8}/* > man_completions.fish
|
||||||
|
@ -20,6 +20,7 @@ THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS" AND
|
||||||
import string, sys, re, os.path, bz2, gzip, traceback, getopt, errno, codecs
|
import string, sys, re, os.path, bz2, gzip, traceback, getopt, errno, codecs
|
||||||
from deroff import Deroffer
|
from deroff import Deroffer
|
||||||
|
|
||||||
|
sys.dont_write_bytecode = True
|
||||||
lzma_available = True
|
lzma_available = True
|
||||||
try:
|
try:
|
||||||
try:
|
try:
|
||||||
|
|
|
@ -1,4 +1,4 @@
|
||||||
#!/usr/bin/env python -B
|
#!/usr/bin/env python
|
||||||
# -*- coding: utf-8 -*-
|
# -*- coding: utf-8 -*-
|
||||||
|
|
||||||
""" Deroff.py, ported to Python from the venerable deroff.c """
|
""" Deroff.py, ported to Python from the venerable deroff.c """
|
||||||
|
@ -6,6 +6,7 @@
|
||||||
|
|
||||||
import sys, re, string
|
import sys, re, string
|
||||||
|
|
||||||
|
sys.dont_write_bytecode = True
|
||||||
IS_PY3 = sys.version_info[0] >= 3
|
IS_PY3 = sys.version_info[0] >= 3
|
||||||
|
|
||||||
class Deroffer:
|
class Deroffer:
|
||||||
|
|
Loading…
Reference in a new issue