Commit Graph

15 Commits

Author SHA1 Message Date
Fabian Homborg
c2970f9618 Reformat all files
This runs build_tools/style.fish, which runs clang-format on C++, fish_indent on fish and (new) black on python.

If anything is wrong with the formatting, we should fix the tools, but automated formatting is worth it.
2019-05-05 12:09:25 +02:00
Benjamin Nied
e7bfd1d71c Remove shebangs from py scripts
Starting with Fedora 30 and RHEL 8, ambiguous python shebangs will now
throw errors during the RPM build process instead of just warnings,
since these systems have moved to Python 3 by default, and Python 2 may
not be available in the future.

See [this
page](https://fedoraproject.org/wiki/Changes/Make_ambiguous_python_shebangs_error)
for more details.

Drop these shebangs as the scripts are only ever called from fish
wrappers.
2019-01-06 20:39:04 +08:00
Kurtis Rader
f33ece11ac simplify invoking create_manpage_completions.py
My previous change to avoid creating a *.pyc file when running
create_manpage_completions.py was wrong because I put the
`sys.dont_write_bytecode = True` on the wrong line. Rather than simply
move that statement make the simpler, cleaner, fix that removes the need
for `eval` where that program is invoked.
2016-10-09 18:42:55 -07:00
Kurtis Rader
92e14d7e4a 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.
2016-10-09 15:09:44 -07:00
Kurtis Rader
213ef3ee56 don't produce *.pyc files
Producing man pages is done infrequently (basically just at `make test`
and `make install`) so there isn't any point in writing compiled
byte-code versions of the python modules.
2016-10-09 14:11:04 -07:00
Aaron Gyes
bb6ce9d142 minor create_manpage_completions.py improvements
Don't truncate long lines with " [See Man Page]" suffix - use the
reclaimed 15 characters for more-useful usage info.

Improve the --verbose output with:
 - spacing fixes
 - diagnostics related to input print repr()/quoted as %r to be less
   confusing.
 - get rid of stupid name() and use type()/__class__.__name__,

- Always use new-style (new as in post python 2.2) classes so this
  behaves the same whether we run in python 2 or 3.

- Properly convert left-quotes and right-quotes to that character in
  deroff.py
2016-07-09 05:51:32 -07:00
Łukasz Niemier
47df1ae40a Remove trailing whitespaces and change tabs to spaces 2012-11-18 11:23:22 +01:00
ridiculousfish
9228dffe5e Don't generate completions if we already have bespoke completions in the data directory
Fixes https://github.com/fish-shell/fish-shell/issues/148
Also fix some Python3 issues
2012-06-18 13:59:34 -07:00
Adam
85f808130d Manpage generation now works with python3 2012-06-05 15:26:11 -07:00
ridiculousfish
f977dfcfe7 Deroffer optimizations 2012-04-15 19:22:30 -07:00
ridiculousfish
15079fa3bd Some more deroff optimizations 2012-04-15 04:41:20 -07:00
ridiculousfish
79a92120ef Speed improvements to deroffer 2012-04-15 01:15:10 -07:00
ridiculousfish
49ece586d5 Added a fish_update_completions function to run the manpage completion file
Added some pretty progress reporting to that script
Added some comments to deroff.py
2012-04-11 19:05:43 -07:00
ridiculousfish
ceb32f63e7 Deroffing completion work 2012-04-09 20:17:54 -07:00
ridiculousfish
576c12b184 Deroffer work 2012-04-09 20:17:54 -07:00