Commit graph

1263 commits

Author SHA1 Message Date
neiljp (Neil Pilgrim) dd283d88f6 bots: zulip_bot_output.py: Adjust examples in help text. 2017-10-05 11:59:56 -07:00
neiljp (Neil Pilgrim) 682ef81970 bots: zulip_bot_output.py: Use built-in argparse formatting for usage. 2017-10-05 11:59:56 -07:00
neiljp (Neil Pilgrim) 7835f1cc19 bots: zulip_bot_output.py: Add note to usage re using quotes. 2017-10-05 11:59:56 -07:00
neiljp (Neil Pilgrim) 4fff603f44 bots: zulip_bot_output.py: Switch message to being required. 2017-10-05 11:59:56 -07:00
neiljp (Neil Pilgrim) c33ac65ac9 define bot: add check & test to avoid sending words with non-letters. 2017-10-05 11:54:43 -07:00
neiljp (Neil Pilgrim) f862cf2222 wikipedia bot: encode urls correctly in http request & adjust tests. 2017-10-05 11:54:43 -07:00
Eeshan Garg 8adf51890a bots/xkcd: Improve and refactor doc.md to use Markdown macros.
This commit does the following:
* Minor improvements to the writing wherever possible.
* Replace links to screenshots with links that would work when
  rendering said screenshots on the main repo. This would mean
  the screenshots won't be rendered outside the main repo.
* Adds a section that links to our Bots Guide's How to run a bot
  tutorial by using a Markdown a macro.
2017-10-03 18:11:38 -07:00
Eeshan Garg 4a162ba625 bots/xkcd: Add a logo. 2017-10-03 18:11:38 -07:00
neiljp (Neil Pilgrim) 34515454b5 bots: Mark --message/-m argument to zulip_bot_output.py as required. 2017-09-30 21:53:51 +02:00
Tim Abbott 807afd2032 zephyr: Use add_default_arguments in sync_public_streams. 2017-09-29 16:21:18 -07:00
Alena Volkova c3a213269f provision: Make sure the correct version of pip is installed.
pip 8.0+ is required to successfully run the script (otherwise, the prefix
option doesn't work). pip 9.0+ is installed because of the safety features.
2017-09-29 16:00:01 -07:00
Alena Volkova e1def40edc provision: Remove unnecessary imports. 2017-09-29 15:58:00 -07:00
Alena Volkova 21bc4778b0 provision: Give a clear error message when virtualenv is missing.
Without this tweak, running the script results in a vague "No such file or
directory" error if the virtualenv package is not installed.
2017-09-29 15:57:23 -07:00
derAnfaenger 449d5faa59 mypy: Run mypy for each package separately. 2017-09-27 20:40:08 -07:00
derAnfaenger abe9338cfe mypy: Add erroring files to exclude list. 2017-09-27 11:44:28 +02:00
derAnfaenger 174d11ec36 lister: Make excluding directories work on Windows. 2017-09-27 11:44:20 +02:00
derAnfaenger 9ddb5518f4 tools: Remove duplicate lister.py 2017-09-27 10:49:41 +02:00
derAnfaenger 5ecc26886a travis: Run mypy and linter in a single job. 2017-09-27 10:27:37 +02:00
neiljp (Neil Pilgrim) 85f2a9e03d bots: Add basic metadata with failover, used on running only. 2017-09-25 14:39:02 -07:00
Eeshan Garg 5681b6e9e2 zulip_bots: Remove get_bot_doc_path and get_bot_logo_path.
These functions were rendered redundant by changes in our
approach on how the main repo renders docs and logos contained
in the zulip_bots package (see #6103). So, these should now be
removed.
2017-09-16 17:10:12 -02:30
Tim Abbott baa09bc26c log2zulip: Clean up extra config path and add comments.
That extra complexity isn't particularly valuable.
2017-09-15 07:04:36 -07:00
derAnfaenger b53dc5de4c log2zulip: Make paths Windows compatible. 2017-09-15 07:04:36 -07:00
derAnfaenger 761d4f44c1 log2zulip: Use default argparser. 2017-09-15 07:04:36 -07:00
derAnfaenger 3af373adc3 travis: Add mypy checker. 2017-09-15 13:24:42 +02:00
derAnfaenger 123c49291a provision: Don't fail on mypy install for Python 2. 2017-09-15 13:24:35 +02:00
derAnfaenger 3fb640a5d0 zulip: Use canonical way to require an arg in subscribe. 2017-09-15 13:24:32 +02:00
derAnfaenger a06437c4ee zulip: Use canonical way to require an arg in unsubscribe. 2017-09-15 13:24:28 +02:00
derAnfaenger 0a49638e82 mypy: Add annotations to api_examples.py 2017-09-15 13:24:24 +02:00
derAnfaenger 035f0c3268 tools: Add mypy runner.
Unless otherwise specified, `tools/run-mypy` will right now only
check annotations in core files of the `zulip` package.
2017-09-15 13:24:20 +02:00
derAnfaenger 61de5578f2 mypy: Fix annotations in core zulip files. 2017-09-15 13:24:09 +02:00
derAnfaenger 59d65309c7 zulip: Exit with info after provisioning script. 2017-09-15 03:06:17 -07:00
derAnfaenger 091f532da6 zulip-api-examples: Check and print path to script. 2017-09-15 02:06:38 -07:00
derAnfaenger 6630deda6a twitter bots: Merge twitter-bot and twitter-search-bot. 2017-09-15 00:55:01 -07:00
derAnfaenger 623557d189 zulip: Install all example scripts in the package's dir. 2017-09-14 04:46:13 -07:00
derAnfaenger 2f044b44bd zulip: Move examples to zulip/examples. 2017-09-14 04:46:13 -07:00
derAnfaenger 2f62507987 api: Add script to print path of examples directory.
Partially fixes #92.
2017-09-14 04:46:13 -07:00
derAnfaenger ae4bf8bbf4 zulip: Store examples in the package's directory. 2017-09-14 04:46:13 -07:00
derAnfaenger 54eac5e125 codecov: Adjust failure threshold.
The previous threshold was taken over from the zulip repo,
which contains much more LOC. The new threshold reflects the
size of the `python-zulip-api` repo.
2017-09-14 04:26:12 -07:00
derAnfaenger 59320f6b28 zulip: Explain use cases for generate_option_group() method. 2017-09-14 11:39:11 +02:00
derAnfaenger 631c64ca6c zulip: Move from simplejson to json.
This removes the simplejson dependency.
2017-09-14 02:26:56 -07:00
derAnfaenger 18157095c4 zulip_bots: Add unittests for run.py.
These are tests that assert the correct argument
parsing; the successful execution of bots is not verified.
2017-09-13 00:25:16 -07:00
derAnfaenger 20f01fec85 provision: Put venv activation path in quotes.
This makes the command work with Windows paths with spaces in them.
2017-09-12 16:48:37 +02:00
derAnfaenger 6aece20925 provision: Indent venv activation command. 2017-09-12 16:47:22 +02:00
derAnfaenger 3e1d9b17a4 zulip_bots: Import imp.load_source for Python < 3.5. 2017-09-12 05:21:00 -07:00
derAnfaenger ea105ffec5 tools: Add git utility scripts. 2017-09-12 02:54:10 -07:00
derAnfaenger d05e932968 log2zulip: Replace ujson with json. 2017-09-12 02:14:51 -07:00
derAnfaenger 7d1a56fb2b zulip_bot_output.py: Refactor script output.
This involves using the format() method for string
concatenation and splitting it into logical blocks.
2017-09-12 02:11:30 -07:00
derAnfaenger 517fe79e68 zulip_bot_output.py: Remove redundant get_config_info() definition. 2017-09-12 02:11:30 -07:00
derAnfaenger 438dbac12a zulip_bot_output.py: Make --path-to-bot argument positional.
This allows a user to exclusively enter a bot's name or a bot's
directory as the first and only positional argument. Therefore,
no complicated checks for multiple bot specifications are required
anymore.
Additionally, this cleans help messages and makes arguments more
accessible.
2017-09-12 02:11:30 -07:00
derAnfaenger 3a89b9f966 zulip_bot_output.py: Clear import statements. 2017-09-12 02:11:30 -07:00