Commit Graph

91 Commits

Author SHA1 Message Date
Robert Craigie 421b05ec61 Add generated types for `c` in `config.py` 2024-10-25 23:34:50 +01:00
Florian Bruhin 0718b25796 reuse: Initial copyright text update for myself
git ls-files | \
    xargs sed -Ei 's/Copyright [0-9]{4}(-[0-9]{4}) Florian Bruhin \(The Compiler\) <mail@qutebrowser\.org>/SPDX-FileCopyrightText: Florian Bruhin (The Compiler) <mail@qutebrowser.org>/'
2023-07-23 12:49:05 +02:00
Florian Bruhin 77ca342cff reuse: Remove some more old license headers
git ls-files | \
xargs grep -l "This file is part of qutebrowser" | \
xargs grep -l SPDX-License-Identifier | \
xargs sed -i '/# This file is part of qutebrowser\./,/along with qutebrowser\.  If not, see <https:\/\/www\.gnu.org\/licenses\/>./d'
2023-07-23 12:15:03 +02:00
Florian Bruhin b2aaba6043 reuse: Adjust most license headers
git ls-files | xargs grep -l "is free software"  | xargs reuse annotate --license="GPL-3.0-or-later" --skip-unrecognised
2023-07-23 12:11:07 +02:00
Philipp Albrecht d9e8b638bf Remove vim modelines
We're deprecating vim modelines in favor of `.editorconfig`.

Removing vim modelines could be done using two one-liners. Most of the vim modelines
were followed by an empty line, so this one-liner took care of these ones:

```sh
rg '^# vim: .+\n\n' -l | xargs sed -i '/^# vim: /,+1d'
```

Then some of the vim modelines were followed by a pylint configuration line, so running
this one-liner afterwards took care of that:

```sh
rg '^# vim:' -l | xargs sed -i '/^# vim: /d'
```
2023-06-30 11:03:06 +02:00
toofar bbaffa3e34 lint: no-else-raise
Unnecessary "else" after "raise", remove the "else" and de-indent the code inside it
2023-02-06 19:50:22 +13:00
toofar ff8dbc4580 lint: broad-exception-raised
Mostly pretty lazy fixes. Most of the places in the tests we were
already matching on error message, a couple of places we weren't. The
tick-tock one was the only one that wasn't being used right where it was
raised.

Some of them I just changed to RuntimeError because it was shorter than
adding the pylint directive.
2023-02-06 18:53:56 +13:00
Florian Bruhin 6c4e281028 pylint: Fix new unnecessary-lambda-assignment 2022-06-08 12:25:12 +02:00
Florian Bruhin 4c0eea93d6 Fix inconsistent doc generation 2022-03-07 12:02:23 +01:00
Florian Bruhin 8a61bd635a Improve docs for URL patterns
Closes #6454, see #5069
2021-09-08 16:18:28 +02:00
Florian Bruhin 5a4b51a784 Increase vim compatibility
Vim has this, and it's almost easter, so clearly we should have it too.
Also it's from Monty Python, which makes it even more fitting.

HEAD KNIGHT: Ni!
KNIGHTS: Ni! Ni! Ni!
ARTHUR: Who are you?
HEAD KNIGHT: We are the Knights Who Say... Ni!
ARTHUR: No! Not the Knights Who Say Ni!
HEAD KNIGHT: The same!
BEDEVERE: Who are they?
HEAD KNIGHT: We are the keepers of the sacred words: Ni, Pen, and Ni-wom!
RANDOM: Ni-wom!
ARTHUR: Those who hear them seldom live to tell the tale!
HEAD KNIGHT: The Knights Who Say Ni demand a sacrifice!
ARTHUR: Knights of Ni, we are but simple travellers who seek the enchanter who lives beyond these woods.
HEAD KNIGHT: Ni! Ni! Ni! Ni!
ARTHUR and PARTY: Oh, ow!
HEAD KNIGHT: We shall say 'nee' again to you if you do not appease us.
ARTHUR: Well, what is it you want?
HEAD KNIGHT: We want... a shrubbery!
[dramatic chord]
ARTHUR: A what?
HEAD KNIGHT: Ni! Ni!
ARTHUR and PARTY: Oh, ow!
ARTHUR: Please, please! No more! We shall find a shrubbery.
HEAD KNIGHT: You must return here with a shrubbery or else you will never pass through this wood alive!
ARTHUR: O Knights of Ni, you are just and fair, and we will return with a shrubbery.
HEAD KNIGHT: One that looks nice.
ARTHUR: Of course.
HEAD KNIGHT: And not too expensive.
ARTHUR: Yes.
HEAD KNIGHTS: Now... go!

ARTHUR: Old crone! Is there anywhere in this town where we could buy a shrubbery!
[dramatic chord]
CRONE: Who sent you?
ARTHUR: The Knights Who Say Nee.
CRONE: Agh! No! Never! We have no shrubberies here.
ARTHUR: If you do not tell us where we can buy a shrubbery, my friend
and I will say... we will say... `nee'.
CRONE: Agh! Do your worst!
ARTHUR: Very well! If you will not assist us voluntarily,... Ni!
CRONE: No! Never! No shrubberies!
ARTHUR: Ni!
BEDEVERE: Noo! Noo!
ARTHUR: No, no, no, no -- it's not that, it's 'Ni'.
BEDEVERE: Noo!
ARTHUR: No, no -- 'Ni'. You're not doing it properly.
BEDEVERE: Noo! Ni!
ARTHUR: That's it, that's it, you've got it.
ARTHUR and BEDEVERE: Ni! Ni!
ROGER: Are you saying 'Ni' to that old woman?
ARTHUR: Um, yes.
ROGER: Oh, what sad times are these when passing ruffians can say `Ni' at will to old ladies. There is a pestilence upon this land, nothing is sacred. Even those who arrange and design shrubberies are under considerable economic stress at this period in history.
ARTHUR: Did you say `shrubberies'?
ROGER: Yes, shrubberies are my trade -- I am a shrubber. My name is Roger the Shrubber. I arrange, design, and sell shrubberies.
BEDEVERE: Ni!
ARTHUR: No! No, no, no! No!
ARTHUR: O, Knights of Ni, we have brought you your shrubbery. May we go now?
HEAD KNIGHT: It is a good shrubbery. I like the laurels particularly. But there is one small problem.
ARTHUR: What is that?
HEAD KNIGHT: We are now... no longer the Knights Who Say Ni.
RANDOM: Ni!
HEAD KNIGHT: Shh shh. We are now the Knights Who Say Ecky-ecky-ecky- ecky-pikang-zoom-boing-mumble-mumble.
RANDOM: Ni!
HEAD KNIGHT: Therefore, we must give you a test.
ARTHUR: What is this test, O Knights of-- Knights Who 'Til Recently Said Ni?
HEAD KNIGHT: Firstly, you must find... another shrubbery!
[dramatic chord]
ARTHUR: Not another shrubbery!
HEAD KNIGHT: Then, when you have found the shrubbery, you must place it here beside this shrubbery, only slightly higher so you get a two-level effect with a little path running down the middle.
RANDOM: A path! A path! Ni!
HEAD KNIGHT: Then, when you have found the shrubbery, you must cut down the mightiest tree in the forest... with... a herring!
[dramatic chord]
ARTHUR: We shall do no such thing!
HEAD KNIGHT: Oh, please!
ARTHUR: Cut down a tree with a herring? It can't be done.
KNIGHTS: Aaaaugh! Aaaugh!
HEAD KNIGHT: Don't say that word.
ARTHUR: What word?
HEAD KNIGHT: I cannot tell, suffice to say is one of the words the Knights of Ni cannot hear.
ARTHUR: How can we not say the word if you don't tell us what it is?
KNIGHTS: Aaaaugh! Aaaugh!
ARTHUR: What, `is'?
HEAD KNIGHT: No, not `is' -- we couldn't get vary far in life not saying `is'.
BEDEVERE: My liege, it's Sir Robin!
MINSTREL (singing): Packing it in and packing it up
And sneaking away and buggering up
And chickening out and pissing about
Yes, bravely he is throwing in the sponge
ARTHUR: Oh, Robin!
ROBIN: My liege! It's good to see you!
KNIGHTS: Aaaaugh!
HEAD KNIGHT: He said the word!
ARTHUR: Surely you've not given up your quest for the Holy Grail?
MINSTREL (singing): He is sneaking away and buggering up--
ROBIN: Shut up! No, no no-- far from it.
HEAD KNIGHT: He said the word again!
ROBIN: I was looking for it.
KNIGHTS: Aaaaugh!
ROBIN: Uh, here, here in this forest.
ARTHUR: No, it is far from--
KNIGHTS: Aaaaugh!
HEAD KNIGHT: Aaaaugh! Stop saying the word!
ARTHUR: Oh, stop it!
KNIGHTS: Aaaaugh!
HEAD KNIGHT: Oh! He said it again!
ARTHUR: Patsy!
HEAD KNIGHT: Aaugh! I said it! I said it! Ooh! I said it again!
KNIGHTS: Aaaaugh!
2021-03-31 13:10:09 +02:00
Florian Bruhin 3192d98bdc doc: Move backend info above type info
More consistent with other comments (like requiring a restart)
2021-03-12 22:27:11 +01:00
Florian Bruhin 1a4fff1a42 doc: Switch URLs to https 2021-01-26 15:19:01 +01:00
Florian Bruhin 222f1f19a1 Bump copyright years
Closes #6015
2021-01-20 20:06:19 +01:00
Florian Bruhin 22890852b6 Update cheatsheet 2021-01-20 19:39:30 +01:00
Florian Bruhin 2560f9774b doc: Use Python 3.9 simplified usage formatting 2020-12-19 22:24:44 +01:00
Florian Bruhin ff994840f0 doc: Add newline before restart note 2020-08-06 10:34:06 +02:00
Florian Bruhin bae1431703 src2asciidoc: Make sure usage lines are generated with fixed width
Due to a change in Python 3.8, the output depended on the calling terminal's
width. Set a fixed with of 200 (rather than 80) so that we always have the
expanded version for the generated documentation.

See #5393 and
74102c9a5f (diff-837b312b1f3508216ace6adb46492836)
2020-05-22 17:12:51 +02:00
Florian Bruhin c1d67c9ef4 Exclude FontBase from docs 2020-05-10 20:49:21 +02:00
Florian Bruhin 5e9b3d1bd9 Run optipng on images 2020-01-04 22:13:01 +01:00
Florian Bruhin 9e4276db9b Adjust copyrights for 2020 2020-01-04 18:21:17 +01:00
Florian Bruhin 33463325f4 Eschew the extraneous elses
https://www.youtube.com/watch?v=JVVMMULwR4s&t=289
2019-03-13 13:53:09 +01:00
Jay Kamat 3e816f5f8b
Update copyright for 2019 2019-02-22 21:45:08 -08:00
Florian Bruhin 4e99caafb9 Skip hooks for vulture/docs 2018-12-10 16:33:24 +01:00
Florian Bruhin 411c5171a2 Load components dynamically 2018-12-10 12:37:58 +01:00
Florian Bruhin 285db344b3 Allow to document count_tab as "count:" argument 2018-12-03 08:44:51 +01:00
Florian Bruhin ede13c76d9 Fix checking for count in src2asciidoc 2018-12-03 08:44:35 +01:00
Florian Bruhin 19628d0ae9 Move cmdutils.cmd_dict to objects.commands 2018-11-29 14:18:11 +01:00
Florian Bruhin b5253ec473 Fix lint 2018-11-28 13:01:43 +01:00
Florian Bruhin 34815f5cf8 Make bindings.default only settable in autoconfig.yml
Fixes #3131
2018-03-07 18:30:44 +01:00
Florian Bruhin 0d4e20c395 Whitelist config options which support URL patterns 2018-02-20 23:26:22 +01:00
Florian Bruhin 6f028e9ad0 Update copyright years 2018-02-05 12:19:50 +01:00
Daniel Hahler dd0703eddf scripts/dev/src2asciidoc.py: vim: readonly
Set 'readonly' via Vim modeline in generated scripts.
2018-01-22 21:21:54 +01:00
Florian Bruhin 430126dcc8 pylint: Re-enable ungrouped-imports 2017-12-15 23:08:53 +01:00
Florian Bruhin e65c0dd8a7 pylint: Re-enable bad-continuation
And lots and lots of whitespace changes.
2017-12-15 19:16:55 +01:00
Florian Bruhin b5dd647678 Upgrade pydocstyle/flake8-docstrings
See #3320
2017-11-26 20:30:32 +01:00
Florian Bruhin f6cc6677dd Remove hiding of commands
This was often confusing for people - let's instead just hide commands which are
not available in normal mode.
2017-11-13 09:02:16 +01:00
Florian Bruhin f6e6f9d27b Make qutebrowser aware of settings requiring a restart
See #3270
2017-11-12 17:17:19 +01:00
Gyorgy Orban bb54a954fe use subprocess run
The usage of subprocess.run is recommended since python 3.5.
Popen, check_call, call and check_output calls were replaced with run.
2017-11-01 09:59:32 +01:00
Florian Bruhin 984dd1ba8c Fix remaining pylint/flake8 issues 2017-10-24 09:37:10 +02:00
siddhugolu 570f1a849f modified as requested 2017-10-24 12:20:07 +05:30
siddhugolu bc9d305354 modified as requested 2017-10-23 01:46:02 +05:30
siddhugolu 4862b2faf9 modified pylint pragmas 2017-10-22 23:52:35 +05:30
Florian Bruhin 36857d9250 Remove valid values for Bool from docs 2017-10-04 11:46:42 +02:00
Florian Bruhin 64e0313090 Fix commas in settings docs
Otherwise, asciidoc interprets it as a third parameter to the xref...

Fixes #3046
2017-10-02 20:12:32 +02:00
Florian Bruhin 9607f3de59 Improve type documentation of settings
Use .get_name() for the docs
2017-09-27 08:25:52 +02:00
Florian Bruhin 413c7ec1ac Add config type docstrings to settings.asciidoc 2017-09-15 17:21:11 +02:00
Ryan Roden-Corrent 71b71dbc58 Merge remote-tracking branch 'upstream/master' into HEAD 2017-08-06 18:13:49 -04:00
Florian Bruhin 7e36310e8a Shorten and update README 2017-07-21 13:28:23 +02:00
Florian Bruhin cff61fa0bc Fix pylint
This also reverts commit 8df0b063be.
2017-07-04 15:34:10 +02:00