Consistently use /usr/bin/env python2.7 in shebangs and commands.

This commit is contained in:
Steven Oud 2015-10-04 18:56:26 +02:00 committed by Luke Faraone
parent 136c55e43d
commit d5435fad1d
124 changed files with 166 additions and 166 deletions

View File

@ -42,7 +42,7 @@ It will correctly not count server-initiated reloads in the activity statistics.
The duration flag can be used to control how many days to show usage duration for The duration flag can be used to control how many days to show usage duration for
Usage: python manage.py analyze_user_activity [--realm=zulip.com] [--date=2013-09-10] [--duration=1] Usage: python2.7 manage.py analyze_user_activity [--realm=zulip.com] [--date=2013-09-10] [--duration=1]
By default, if no date is selected 2013-09-10 is used. If no realm is provided, information By default, if no date is selected 2013-09-10 is used. If no realm is provided, information
is shown for all realms""" is shown for all realms"""

View File

@ -13,9 +13,9 @@ class Command(BaseCommand):
Usage examples: Usage examples:
python manage.py client_activity python2.7 manage.py client_activity
python manage.py client_activity zulip.com python2.7 manage.py client_activity zulip.com
python manage.py client_activity jesstess@zulip.com""" python2.7 manage.py client_activity jesstess@zulip.com"""
def add_arguments(self, parser): def add_arguments(self, parser):
parser.add_argument('arg', metavar='<arg>', type=str, nargs='?', default=None, parser.add_argument('arg', metavar='<arg>', type=str, nargs='?', default=None,

View File

@ -1,4 +1,4 @@
#!/usr/bin/env python #!/usr/bin/env python2.7
# -*- coding: utf-8 -*- # -*- coding: utf-8 -*-
# zulip-send -- Sends a message to the specified recipients. # zulip-send -- Sends a message to the specified recipients.

View File

@ -1,4 +1,4 @@
#!/usr/bin/python #!/usr/bin/env python2.7
# -*- coding: utf-8 -*- # -*- coding: utf-8 -*-
# Copyright © 2012-2014 Zulip, Inc. # Copyright © 2012-2014 Zulip, Inc.

View File

@ -1,4 +1,4 @@
#!/usr/bin/env python #!/usr/bin/env python2.7
# -*- coding: utf-8 -*- # -*- coding: utf-8 -*-
# Copyright © 2012 Zulip, Inc. # Copyright © 2012 Zulip, Inc.

View File

@ -1,4 +1,4 @@
#!/usr/bin/env python #!/usr/bin/env python2.7
# -*- coding: utf-8 -*- # -*- coding: utf-8 -*-
# Copyright © 2012 Zulip, Inc. # Copyright © 2012 Zulip, Inc.

View File

@ -1,4 +1,4 @@
#!/usr/bin/env python #!/usr/bin/env python2.7
# -*- coding: utf-8 -*- # -*- coding: utf-8 -*-
# Copyright © 2014 Zulip, Inc. # Copyright © 2014 Zulip, Inc.

View File

@ -1,4 +1,4 @@
#!/usr/bin/env python #!/usr/bin/env python2.7
# -*- coding: utf-8 -*- # -*- coding: utf-8 -*-
# Copyright © 2012 Zulip, Inc. # Copyright © 2012 Zulip, Inc.

View File

@ -1,4 +1,4 @@
#!/usr/bin/env python #!/usr/bin/env python2.7
# -*- coding: utf-8 -*- # -*- coding: utf-8 -*-
# Copyright © 2012 Zulip, Inc. # Copyright © 2012 Zulip, Inc.

View File

@ -1,4 +1,4 @@
#!/usr/bin/env python #!/usr/bin/env python2.7
# -*- coding: utf-8 -*- # -*- coding: utf-8 -*-
# Copyright © 2012 Zulip, Inc. # Copyright © 2012 Zulip, Inc.

View File

@ -1,4 +1,4 @@
#!/usr/bin/env python #!/usr/bin/env python2.7
# -*- coding: utf-8 -*- # -*- coding: utf-8 -*-
# Copyright © 2012 Zulip, Inc. # Copyright © 2012 Zulip, Inc.

View File

@ -1,4 +1,4 @@
#!/usr/bin/env python #!/usr/bin/env python2.7
# -*- coding: utf-8 -*- # -*- coding: utf-8 -*-
# Copyright © 2012 Zulip, Inc. # Copyright © 2012 Zulip, Inc.

View File

@ -1,4 +1,4 @@
#!/usr/bin/env python #!/usr/bin/env python2.7
# -*- coding: utf-8 -*- # -*- coding: utf-8 -*-
# Copyright © 2012 Zulip, Inc. # Copyright © 2012 Zulip, Inc.

View File

@ -1,4 +1,4 @@
#!/usr/bin/env python #!/usr/bin/env python2.7
# -*- coding: utf-8 -*- # -*- coding: utf-8 -*-
# Copyright © 2012 Zulip, Inc. # Copyright © 2012 Zulip, Inc.

View File

@ -1,4 +1,4 @@
#!/usr/bin/env python #!/usr/bin/env python2.7
# -*- coding: utf-8 -*- # -*- coding: utf-8 -*-
# #
# Copyright © 2014 Zulip, Inc. # Copyright © 2014 Zulip, Inc.

View File

@ -1,4 +1,4 @@
#!/usr/bin/env python #!/usr/bin/env python2.7
# -*- coding: utf-8 -*- # -*- coding: utf-8 -*-
# #
# Asana integration for Zulip # Asana integration for Zulip

View File

@ -1,4 +1,4 @@
#!/usr/bin/env python #!/usr/bin/env python2.7
# -*- coding: utf-8 -*- # -*- coding: utf-8 -*-
# #
# Copyright © 2014 Zulip, Inc. # Copyright © 2014 Zulip, Inc.

View File

@ -1,4 +1,4 @@
#!/usr/bin/env python #!/usr/bin/env python2.7
# -*- coding: utf-8 -*- # -*- coding: utf-8 -*-
# #
# Zulip mirror of Basecamp activity # Zulip mirror of Basecamp activity

View File

@ -1,4 +1,4 @@
#!/usr/bin/env python #!/usr/bin/env python2.7
# -*- coding: utf-8 -*- # -*- coding: utf-8 -*-
# #
# Copyright © 2014 Zulip, Inc. # Copyright © 2014 Zulip, Inc.

View File

@ -1,4 +1,4 @@
#!/usr/bin/env python #!/usr/bin/env python2.7
# -*- coding: utf-8 -*- # -*- coding: utf-8 -*-
# #
# Zulip mirror of Codebase HQ activity # Zulip mirror of Codebase HQ activity

View File

@ -1,4 +1,4 @@
#!/usr/bin/env python #!/usr/bin/env python2.7
# -*- coding: utf-8 -*- # -*- coding: utf-8 -*-
# #
# Zulip notification post-receive hook. # Zulip notification post-receive hook.

View File

@ -1,4 +1,4 @@
#!/usr/bin/env python #!/usr/bin/env python2.7
# -*- coding: utf-8 -*- # -*- coding: utf-8 -*-
# #
# Copyright © 2014 Zulip, Inc. # Copyright © 2014 Zulip, Inc.

View File

@ -1,4 +1,4 @@
#!/usr/bin/env python #!/usr/bin/env python2.7
# -*- coding: utf-8 -*- # -*- coding: utf-8 -*-
# #
# Zulip hook for Mercurial changeset pushes. # Zulip hook for Mercurial changeset pushes.

View File

@ -1,4 +1,4 @@
#!/usr/bin/env python #!/usr/bin/env python2.7
import optparse import optparse
import zulip import zulip

View File

@ -1,4 +1,4 @@
#!/usr/bin/env python #!/usr/bin/env python2.7
# #
# git-p4.py -- A tool for bidirectional operation between a Perforce depot and git. # git-p4.py -- A tool for bidirectional operation between a Perforce depot and git.
# #

View File

@ -1,4 +1,4 @@
#!/usr/bin/env python #!/usr/bin/env python2.7
# -*- coding: utf-8 -*- # -*- coding: utf-8 -*-
# #
# Copyright © 2012-2014 Zulip, Inc. # Copyright © 2012-2014 Zulip, Inc.

View File

@ -1,4 +1,4 @@
#!/usr/bin/env python #!/usr/bin/env python2.7
# -*- coding: utf-8 -*- # -*- coding: utf-8 -*-
# #
# Copyright © 2014 Zulip, Inc. # Copyright © 2014 Zulip, Inc.

View File

@ -1,4 +1,4 @@
#!/usr/bin/env python #!/usr/bin/env python2.7
# -*- coding: utf-8 -*- # -*- coding: utf-8 -*-
# #
# RSS integration for Zulip # RSS integration for Zulip

View File

@ -1,4 +1,4 @@
#!/usr/bin/env python #!/usr/bin/env python2.7
# -*- coding: utf-8 -*- # -*- coding: utf-8 -*-
# #
# Zulip notification post-commit hook. # Zulip notification post-commit hook.

View File

@ -1,4 +1,4 @@
#!/usr/bin/env python #!/usr/bin/env python2.7
# -*- coding: utf-8 -*- # -*- coding: utf-8 -*-
# #
# Copyright © 2014 Zulip, Inc. # Copyright © 2014 Zulip, Inc.

View File

@ -1,4 +1,4 @@
#!/usr/bin/env python #!/usr/bin/env python2.7
# -*- coding: utf-8 -*- # -*- coding: utf-8 -*-
# #
# Twitter integration for Zulip # Twitter integration for Zulip

View File

@ -1,4 +1,4 @@
#!/usr/bin/env python #!/usr/bin/env python2.7
# -*- coding: utf-8 -*- # -*- coding: utf-8 -*-
# #
# Twitter search integration for Zulip # Twitter search integration for Zulip

View File

@ -1,4 +1,4 @@
#!/usr/bin/env python #!/usr/bin/env python2.7
# -*- coding: utf-8 -*- # -*- coding: utf-8 -*-
import os import os

View File

@ -1,4 +1,4 @@
#!/usr/bin/env python #!/usr/bin/env python2.7
import xml.etree.ElementTree as ET import xml.etree.ElementTree as ET
import subprocess import subprocess

View File

@ -1,4 +1,4 @@
#!/usr/bin/env python #!/usr/bin/env python2.7
from __future__ import absolute_import from __future__ import absolute_import
import os import os

View File

@ -1,4 +1,4 @@
#!/usr/bin/env python #!/usr/bin/env python2.7
import sys import sys
import logging import logging
import os import os

View File

@ -1,4 +1,4 @@
#!/usr/bin/env python #!/usr/bin/env python2.7
import sys import sys
import time import time
import optparse import optparse

View File

@ -1,4 +1,4 @@
#!/usr/bin/env python #!/usr/bin/env python2.7
import sys import sys
import time import time

View File

@ -1,4 +1,4 @@
#!/usr/bin/env python #!/usr/bin/env python2.7
import sys import sys
import re import re

View File

@ -1,4 +1,4 @@
#!/usr/bin/env python #!/usr/bin/env python2.7
import time import time
def nagios_from_file(results_file): def nagios_from_file(results_file):

View File

@ -1,4 +1,4 @@
#!/usr/bin/env python #!/usr/bin/env python2.7
import sys import sys
import time import time
import datetime import datetime

View File

@ -1,4 +1,4 @@
#! /usr/bin/env python #! /usr/bin/env python2.7
# #
# EXPERIMENTAL # EXPERIMENTAL
# IRC <=> Zulip mirroring bot # IRC <=> Zulip mirroring bot
@ -92,11 +92,11 @@ class IRCBot(irc.bot.SingleServerIRCBot):
return return
self.dcc_connect(address, port) self.dcc_connect(address, port)
usage = """python irc-mirror.py --server=IRC_SERVER --channel=<CHANNEL> --nick-prefix=<NICK> [optional args] usage = """python2.7 irc-mirror.py --server=IRC_SERVER --channel=<CHANNEL> --nick-prefix=<NICK> [optional args]
Example: Example:
python irc-mirror.py --irc-server=127.0.0.1 --channel='#test' --nick-prefix=username python2.7 irc-mirror.py --irc-server=127.0.0.1 --channel='#test' --nick-prefix=username
--site=https://zulip.example.com --user=irc-bot@example.com --site=https://zulip.example.com --user=irc-bot@example.com
--api-key=xxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx --api-key=xxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx

View File

@ -1,4 +1,4 @@
#!/usr/bin/env python #!/usr/bin/env python2.7
# Copyright (C) 2014 Zulip, Inc. # Copyright (C) 2014 Zulip, Inc.
# #
# Permission is hereby granted, free of charge, to any person # Permission is hereby granted, free of charge, to any person

View File

@ -1,4 +1,4 @@
#!/usr/bin/python #!/usr/bin/env python2.7
# #
# Copyright (C) 2013 Permabit, Inc. # Copyright (C) 2013 Permabit, Inc.
# Copyright (C) 2013--2014 Zulip, Inc. # Copyright (C) 2013--2014 Zulip, Inc.

View File

@ -1,4 +1,4 @@
#!/usr/bin/python #!/usr/bin/env python2.7
import subprocess import subprocess
import os import os
import sys import sys

View File

@ -1,4 +1,4 @@
#!/usr/bin/python #!/usr/bin/env python2.7
import sys import sys
import subprocess import subprocess
import base64 import base64

View File

@ -1,4 +1,4 @@
#!/usr/bin/env python #!/usr/bin/env python2.7
import sys import sys
import os import os
import logging import logging

View File

@ -1,4 +1,4 @@
#!/usr/bin/env python #!/usr/bin/env python2.7
# Copyright (C) 2012 Zulip, Inc. # Copyright (C) 2012 Zulip, Inc.
# #
# Permission is hereby granted, free of charge, to any person # Permission is hereby granted, free of charge, to any person

View File

@ -1,4 +1,4 @@
#!/usr/bin/env python #!/usr/bin/env python2.7
# Copyright (C) 2012 Zulip, Inc. # Copyright (C) 2012 Zulip, Inc.
# #
# Permission is hereby granted, free of charge, to any person # Permission is hereby granted, free of charge, to any person

View File

@ -1,4 +1,4 @@
#!/usr/bin/env python #!/usr/bin/env python2.7
# Copyright (C) 2012 Zulip, Inc. # Copyright (C) 2012 Zulip, Inc.
# #
# Permission is hereby granted, free of charge, to any person # Permission is hereby granted, free of charge, to any person

View File

@ -352,8 +352,8 @@ styles (separate lines for each selector)::
Python Python
------ ------
- Scripts should start with ``#!/usr/bin/env python`` and not - Scripts should start with ``#!/usr/bin/env python2.7`` and not
``#!/usr/bin/python``. See commit ``437d4aee`` for an explanation of ``#!/usr/bin/env python2.7``. See commit ``437d4aee`` for an explanation of
why. Don't put such a line on a Python file unless it's meaningful to why. Don't put such a line on a Python file unless it's meaningful to
run it as a script. (Some libraries can also be run as scripts, e.g. run it as a script. (Some libraries can also be run as scripts, e.g.
to run a test suite.) to run a test suite.)

View File

@ -1,4 +1,4 @@
#!/usr/bin/env python3 #!/usr/bin/env python2.7
# Remove HTML entity escaping left over from MediaWiki->rST conversion. # Remove HTML entity escaping left over from MediaWiki->rST conversion.

View File

@ -1,4 +1,4 @@
#!/usr/bin/env python #!/usr/bin/env python2.7
import os import os
import sys import sys
import logging import logging

View File

@ -1,4 +1,4 @@
#!/usr/bin/env python #!/usr/bin/env python2.7
""" """
Nagios plugin to check that none of our queue workers have reported errors. Nagios plugin to check that none of our queue workers have reported errors.

View File

@ -1,4 +1,4 @@
#!/usr/bin/env python #!/usr/bin/env python2.7
import psycopg2 import psycopg2
import psycopg2.extensions import psycopg2.extensions
import select import select

View File

@ -8,7 +8,7 @@
; variables can be expanded using this syntax: "%(ENV_HOME)s". ; variables can be expanded using this syntax: "%(ENV_HOME)s".
[fcgi-program:zulip-django] [fcgi-program:zulip-django]
command=python /home/zulip/deployments/current/manage.py runfcgi daemonize=False maxchildren=20 ; the program (relative uses PATH, can take args) command=python2.7 /home/zulip/deployments/current/manage.py runfcgi daemonize=False maxchildren=20 ; the program (relative uses PATH, can take args)
;process_name=%(program_name)s ; process_name expr (default %(program_name)s) ;process_name=%(program_name)s ; process_name expr (default %(program_name)s)
;numprocs=1 ; number of processes copies to start (def 1) ;numprocs=1 ; number of processes copies to start (def 1)
;directory=/tmp ; directory to cwd to before exec (def no cwd) ;directory=/tmp ; directory to cwd to before exec (def no cwd)
@ -43,7 +43,7 @@ socket_owner=zulip:zulip
socket_mode=0700 socket_mode=0700
[program:zulip-tornado] [program:zulip-tornado]
command=python /home/zulip/deployments/current/manage.py runtornado localhost:9993 command=python2.7 /home/zulip/deployments/current/manage.py runtornado localhost:9993
priority=200 ; the relative start priority (default 999) priority=200 ; the relative start priority (default 999)
autostart=true ; start at supervisord start (default: true) autostart=true ; start at supervisord start (default: true)
autorestart=true ; whether/when to restart (default: unexpected) autorestart=true ; whether/when to restart (default: unexpected)
@ -57,7 +57,7 @@ stdout_logfile_backups=10 ; # of stdout logfile backups (default 10)
directory=/home/zulip/deployments/current/ directory=/home/zulip/deployments/current/
[program:zulip-events-user-activity] [program:zulip-events-user-activity]
command=python /home/zulip/deployments/current/manage.py process_queue user_activity command=python2.7 /home/zulip/deployments/current/manage.py process_queue user_activity
priority=300 ; the relative start priority (default 999) priority=300 ; the relative start priority (default 999)
autostart=true ; start at supervisord start (default: true) autostart=true ; start at supervisord start (default: true)
autorestart=true ; whether/when to restart (default: unexpected) autorestart=true ; whether/when to restart (default: unexpected)
@ -71,7 +71,7 @@ stdout_logfile_backups=10 ; # of stdout logfile backups (default 10)
directory=/home/zulip/deployments/current/ directory=/home/zulip/deployments/current/
[program:zulip-events-user-activity-interval] [program:zulip-events-user-activity-interval]
command=python /home/zulip/deployments/current/manage.py process_queue user_activity_interval command=python2.7 /home/zulip/deployments/current/manage.py process_queue user_activity_interval
priority=300 ; the relative start priority (default 999) priority=300 ; the relative start priority (default 999)
autostart=true ; start at supervisord start (default: true) autostart=true ; start at supervisord start (default: true)
autorestart=true ; whether/when to restart (default: unexpected) autorestart=true ; whether/when to restart (default: unexpected)
@ -85,7 +85,7 @@ stdout_logfile_backups=10 ; # of stdout logfile backups (default 10)
directory=/home/zulip/deployments/current/ directory=/home/zulip/deployments/current/
[program:zulip-events-user-presence] [program:zulip-events-user-presence]
command=python /home/zulip/deployments/current/manage.py process_queue user_presence command=python2.7 /home/zulip/deployments/current/manage.py process_queue user_presence
priority=300 ; the relative start priority (default 999) priority=300 ; the relative start priority (default 999)
autostart=true ; start at supervisord start (default: true) autostart=true ; start at supervisord start (default: true)
autorestart=true ; whether/when to restart (default: unexpected) autorestart=true ; whether/when to restart (default: unexpected)
@ -99,7 +99,7 @@ stdout_logfile_backups=10 ; # of stdout logfile backups (default 10)
directory=/home/zulip/deployments/current/ directory=/home/zulip/deployments/current/
[program:zulip-events-signups] [program:zulip-events-signups]
command=python /home/zulip/deployments/current/manage.py process_queue signups command=python2.7 /home/zulip/deployments/current/manage.py process_queue signups
priority=400 ; the relative start priority (default 999) priority=400 ; the relative start priority (default 999)
autostart=true ; start at supervisord start (default: true) autostart=true ; start at supervisord start (default: true)
autorestart=true ; whether/when to restart (default: unexpected) autorestart=true ; whether/when to restart (default: unexpected)
@ -113,7 +113,7 @@ stdout_logfile_backups=10 ; # of stdout logfile backups (default 10)
directory=/home/zulip/deployments/current/ directory=/home/zulip/deployments/current/
[program:zulip-events-confirmation-emails] [program:zulip-events-confirmation-emails]
command=python /home/zulip/deployments/current/manage.py process_queue invites command=python2.7 /home/zulip/deployments/current/manage.py process_queue invites
priority=500 ; the relative start priority (default 999) priority=500 ; the relative start priority (default 999)
autostart=true ; start at supervisord start (default: true) autostart=true ; start at supervisord start (default: true)
autorestart=true ; whether/when to restart (default: unexpected) autorestart=true ; whether/when to restart (default: unexpected)
@ -127,7 +127,7 @@ stdout_logfile_backups=10 ; # of stdout logfile backups (default 10)
directory=/home/zulip/deployments/current/ directory=/home/zulip/deployments/current/
[program:zulip-events-missedmessage_reminders] [program:zulip-events-missedmessage_reminders]
command=python /home/zulip/deployments/current/manage.py process_queue missedmessage_emails command=python2.7 /home/zulip/deployments/current/manage.py process_queue missedmessage_emails
priority=600 ; the relative start priority (default 999) priority=600 ; the relative start priority (default 999)
autostart=true ; start at supervisord start (default: true) autostart=true ; start at supervisord start (default: true)
autorestart=true ; whether/when to restart (default: unexpected) autorestart=true ; whether/when to restart (default: unexpected)
@ -141,7 +141,7 @@ stdout_logfile_backups=10 ; # of stdout logfile backups (default 10)
directory=/home/zulip/deployments/current/ directory=/home/zulip/deployments/current/
[program:zulip-events-missedmessage_mobile_notifications] [program:zulip-events-missedmessage_mobile_notifications]
command=python /home/zulip/deployments/current/manage.py process_queue missedmessage_mobile_notifications command=python2.7 /home/zulip/deployments/current/manage.py process_queue missedmessage_mobile_notifications
priority=600 ; the relative start priority (default 999) priority=600 ; the relative start priority (default 999)
autostart=true ; start at supervisord start (default: true) autostart=true ; start at supervisord start (default: true)
autorestart=true ; whether/when to restart (default: unexpected) autorestart=true ; whether/when to restart (default: unexpected)
@ -155,7 +155,7 @@ stdout_logfile_backups=10 ; # of stdout logfile backups (default 10)
directory=/home/zulip/deployments/current/ directory=/home/zulip/deployments/current/
[program:zulip-events-slowqueries] [program:zulip-events-slowqueries]
command=python /home/zulip/deployments/current/manage.py process_queue slow_queries command=python2.7 /home/zulip/deployments/current/manage.py process_queue slow_queries
priority=600 ; the relative start priority (default 999) priority=600 ; the relative start priority (default 999)
autostart=true ; start at supervisord start (default: true) autostart=true ; start at supervisord start (default: true)
autorestart=true ; whether/when to restart (default: unexpected) autorestart=true ; whether/when to restart (default: unexpected)
@ -169,7 +169,7 @@ stdout_logfile_backups=10 ; # of stdout logfile backups (default 10)
directory=/home/zulip/deployments/current/ directory=/home/zulip/deployments/current/
[program:zulip-events-message_sender] [program:zulip-events-message_sender]
command=python /home/zulip/deployments/current/manage.py process_queue message_sender %(process_num)s command=python2.7 /home/zulip/deployments/current/manage.py process_queue message_sender %(process_num)s
process_name=%(program_name)s-%(process_num)s process_name=%(program_name)s-%(process_num)s
priority=350 ; the relative start priority (default 999) priority=350 ; the relative start priority (default 999)
autostart=true ; start at supervisord start (default: true) autostart=true ; start at supervisord start (default: true)
@ -185,7 +185,7 @@ directory=/home/zulip/deployments/current/
numprocs=5 numprocs=5
[program:zulip-events-feedback_messages] [program:zulip-events-feedback_messages]
command=python /home/zulip/deployments/current/manage.py process_queue feedback_messages command=python2.7 /home/zulip/deployments/current/manage.py process_queue feedback_messages
priority=600 ; the relative start priority (default 999) priority=600 ; the relative start priority (default 999)
autostart=true ; start at supervisord start (default: true) autostart=true ; start at supervisord start (default: true)
autorestart=true ; whether/when to restart (default: unexpected) autorestart=true ; whether/when to restart (default: unexpected)
@ -199,7 +199,7 @@ stdout_logfile_backups=10 ; # of stdout logfile backups (default 10)
directory=/home/zulip/deployments/current/ directory=/home/zulip/deployments/current/
[program:zulip-events-error_reports] [program:zulip-events-error_reports]
command=python /home/zulip/deployments/current/manage.py process_queue error_reports command=python2.7 /home/zulip/deployments/current/manage.py process_queue error_reports
priority=600 ; the relative start priority (default 999) priority=600 ; the relative start priority (default 999)
autostart=true ; start at supervisord start (default: true) autostart=true ; start at supervisord start (default: true)
autorestart=true ; whether/when to restart (default: unexpected) autorestart=true ; whether/when to restart (default: unexpected)
@ -213,7 +213,7 @@ stdout_logfile_backups=10 ; # of stdout logfile backups (default 10)
directory=/home/zulip/deployments/current/ directory=/home/zulip/deployments/current/
[program:zulip-events-digest_emails] [program:zulip-events-digest_emails]
command=python /home/zulip/deployments/current/manage.py process_queue digest_emails command=python2.7 /home/zulip/deployments/current/manage.py process_queue digest_emails
priority=600 ; the relative start priority (default 999) priority=600 ; the relative start priority (default 999)
autostart=true ; start at supervisord start (default: true) autostart=true ; start at supervisord start (default: true)
autorestart=true ; whether/when to restart (default: unexpected) autorestart=true ; whether/when to restart (default: unexpected)
@ -227,7 +227,7 @@ stdout_logfile_backups=10 ; # of stdout logfile backups (default 10)
directory=/home/zulip/deployments/current/ directory=/home/zulip/deployments/current/
[program:zulip-events-email_mirror] [program:zulip-events-email_mirror]
command=python /home/zulip/deployments/current/manage.py process_queue email_mirror command=python2.7 /home/zulip/deployments/current/manage.py process_queue email_mirror
priority=600 ; the relative start priority (default 999) priority=600 ; the relative start priority (default 999)
autostart=true ; start at supervisord start (default: true) autostart=true ; start at supervisord start (default: true)
autorestart=true ; whether/when to restart (default: unexpected) autorestart=true ; whether/when to restart (default: unexpected)
@ -241,7 +241,7 @@ stdout_logfile_backups=10 ; # of stdout logfile backups (default 10)
directory=/home/zulip/deployments/current/ directory=/home/zulip/deployments/current/
[program:zulip-deliver-enqueued-emails] [program:zulip-deliver-enqueued-emails]
command=python /home/zulip/deployments/current/manage.py deliver_email command=python2.7 /home/zulip/deployments/current/manage.py deliver_email
priority=600 ; the relative start priority (default 999) priority=600 ; the relative start priority (default 999)
autostart=true ; start at supervisord start (default: true) autostart=true ; start at supervisord start (default: true)
autorestart=true ; whether/when to restart (default: unexpected) autorestart=true ; whether/when to restart (default: unexpected)

View File

@ -32,7 +32,7 @@ Listen 444
SetHandler None SetHandler None
</Location> </Location>
Alias /media/ "/usr/lib/pymodules/python2.7/django/contrib/admin/media/" Alias /media/ "/usr/lib/pymodules/python2/django/contrib/admin/media/"
<Location "/media/"> <Location "/media/">
SetHandler None SetHandler None
</Location> </Location>

View File

@ -1,3 +1,3 @@
MAILTO=root MAILTO=root
*/10 * * * * zulip cd /home/zulip/deployments/current && python manage.py active_user_stats */10 * * * * zulip cd /home/zulip/deployments/current && python2.7 manage.py active_user_stats

View File

@ -1,4 +1,4 @@
MAILTO=root MAILTO=root
# Remove any stale apple device tokens from our list # Remove any stale apple device tokens from our list
0 3 * * * zulip cd /home/zulip/deployments/current && python manage.py check_apns_tokens 0 3 * * * zulip cd /home/zulip/deployments/current && python2.7 manage.py check_apns_tokens

View File

@ -1,4 +1,4 @@
MAILTO=root MAILTO=root
# Clear all expired Django sessions at 10:22 PM every day. # Clear all expired Django sessions at 10:22 PM every day.
22 22 * * * zulip cd /home/zulip/deployments/current && python manage.py clearsessions 22 22 * * * zulip cd /home/zulip/deployments/current && python2.7 manage.py clearsessions

View File

@ -1,4 +1,4 @@
MAILTO=root MAILTO=root
# Send digest emails once a day. Time is in UTC. # Send digest emails once a day. Time is in UTC.
0 18 * * * zulip cd /home/zulip/deployments/current && python manage.py enqueue_digest_emails 0 18 * * * zulip cd /home/zulip/deployments/current && python2.7 manage.py enqueue_digest_emails

View File

@ -1,4 +1,4 @@
#!/usr/bin/python #!/usr/bin/env python2.7
""" """
Nagios plugin to check the length of the FTS update log. Nagios plugin to check the length of the FTS update log.

View File

@ -1,4 +1,4 @@
#!/usr/bin/env python #!/usr/bin/env python2.7
""" """
Nagios plugin to check that Zephyr personals mirrors are forwarding. Nagios plugin to check that Zephyr personals mirrors are forwarding.

View File

@ -1,4 +1,4 @@
#!/usr/bin/python #!/usr/bin/env python2.7
""" """
Nagios plugin to check the difference between the primary and Nagios plugin to check the difference between the primary and

View File

@ -1,4 +1,4 @@
#!/usr/bin/python #!/usr/bin/env python2.7
import dateutil.parser import dateutil.parser
import pytz import pytz

View File

@ -1,4 +1,4 @@
#!/usr/bin/env python #!/usr/bin/env python2.7
""" """
Nagios plugin to check that the rabbitmq has the correct number of consumers Nagios plugin to check that the rabbitmq has the correct number of consumers

View File

@ -1,4 +1,4 @@
#!/usr/bin/env python #!/usr/bin/env python2.7
""" """
Nagios plugin to check that the rabbitmq queues are not overflowing as a result Nagios plugin to check that the rabbitmq queues are not overflowing as a result

View File

@ -1,4 +1,4 @@
#!/usr/bin/env python #!/usr/bin/env python2.7
""" """
Script to provide information about send-receive times. Script to provide information about send-receive times.

View File

@ -1,4 +1,4 @@
#!/usr/bin/env python #!/usr/bin/env python2.7
""" """
Nagios plugin to check that our MIT users' Zephyr mirrors are running. Nagios plugin to check that our MIT users' Zephyr mirrors are running.

View File

@ -1,4 +1,4 @@
#!/usr/bin/env python #!/usr/bin/env python2.7
""" """
Nagios plugin to check that Zephyr mirror forwarding is running. Nagios plugin to check that Zephyr mirror forwarding is running.

View File

@ -1,4 +1,4 @@
#!/usr/bin/python #!/usr/bin/env python2.7
import subprocess import subprocess
import sys import sys

View File

@ -3,7 +3,7 @@
[program:zulip-carbon-cache] [program:zulip-carbon-cache]
command=python /opt/graphite/bin/carbon-cache.py --debug start command=python2.7 /opt/graphite/bin/carbon-cache.py --debug start
priority=200 ; the relative start priority (default 999) priority=200 ; the relative start priority (default 999)
autostart=true ; start at supervisord start (default: true) autostart=true ; start at supervisord start (default: true)
autorestart=true ; whether/when to restart (default: unexpected) autorestart=true ; whether/when to restart (default: unexpected)
@ -15,7 +15,7 @@ stdout_logfile=/var/log/zulip/carbon-cache.log ; stdout log path, NONE f
directory=/home/zulip/ directory=/home/zulip/
[program:zulip-carbon-aggregator] [program:zulip-carbon-aggregator]
command=python /opt/graphite/bin/carbon-aggregator.py --debug start command=python2.7 /opt/graphite/bin/carbon-aggregator.py --debug start
priority=200 ; the relative start priority (default 999) priority=200 ; the relative start priority (default 999)
autostart=true ; start at supervisord start (default: true) autostart=true ; start at supervisord start (default: true)
autorestart=true ; whether/when to restart (default: unexpected) autorestart=true ; whether/when to restart (default: unexpected)

View File

@ -1,4 +1,4 @@
#!/usr/bin/python #!/usr/bin/env python2.7
# -*- coding: utf-8 -*- # -*- coding: utf-8 -*-
# #
# Copyright (C) 2003-2009 Edgewall Software # Copyright (C) 2003-2009 Edgewall Software

View File

@ -1,4 +1,4 @@
#!/usr/bin/python #!/usr/bin/env python2.7
# -*- coding: utf-8 -*- # -*- coding: utf-8 -*-
# #
# Copyright (C) 2003-2009 Edgewall Software # Copyright (C) 2003-2009 Edgewall Software

View File

@ -1,4 +1,4 @@
#!/usr/bin/python #!/usr/bin/env python2.7
# -*- coding: utf-8 -*- # -*- coding: utf-8 -*-
# #
# Copyright (C)2008-2009 Edgewall Software # Copyright (C)2008-2009 Edgewall Software

View File

@ -1,4 +1,4 @@
#!/usr/bin/python #!/usr/bin/env python2.7
# -*- coding: utf-8 -*- # -*- coding: utf-8 -*-
# #
# Copyright © 2013 Zulip, Inc. # Copyright © 2013 Zulip, Inc.

View File

@ -1,4 +1,4 @@
#!/usr/bin/python -u #!/usr/bin/env python2.7 -u
import os import os
import sys import sys
import subprocess import subprocess

View File

@ -1,4 +1,4 @@
#!/usr/bin/python -u #!/usr/bin/env python2.7 -u
import os import os
import sys import sys
import subprocess import subprocess

View File

@ -1,4 +1,4 @@
#!/usr/bin/python -u #!/usr/bin/env python2.7 -u
import subprocess import subprocess
import os import os
import sys import sys

View File

@ -1,4 +1,4 @@
#!/usr/bin/python #!/usr/bin/env python2.7
import sys import sys
import os import os
import logging import logging

View File

@ -1,4 +1,4 @@
#!/usr/bin/env python #!/usr/bin/env python2.7
import os import os
import sys import sys
import pwd import pwd
@ -20,10 +20,10 @@ if pwd.getpwuid(os.getuid())[0] != "zulip":
sys.exit(1) sys.exit(1)
# Send a statsd event on restarting the server # Send a statsd event on restarting the server
subprocess.check_call(["python", "./manage.py", "send_stats", "incr", "events.server_restart", str(int(time.time()))]) subprocess.check_call(["python2.7", "./manage.py", "send_stats", "incr", "events.server_restart", str(int(time.time()))])
logging.info("Filling memcached caches") logging.info("Filling memcached caches")
subprocess.check_call(["python", "./manage.py", "fill_memcached_caches"]) subprocess.check_call(["python2.7", "./manage.py", "fill_memcached_caches"])
# Restart the FastCGI and related processes via supervisorctl. # Restart the FastCGI and related processes via supervisorctl.
logging.info("Stopping workers") logging.info("Stopping workers")

View File

@ -1,4 +1,4 @@
#!/usr/bin/env python #!/usr/bin/env python2.7
# This tools generates local_settings_generated.py using the template # This tools generates local_settings_generated.py using the template
import sys, os, os.path import sys, os, os.path

View File

@ -3,12 +3,12 @@
# Change to root directory of the checkout that we're running from # Change to root directory of the checkout that we're running from
cd "$(dirname "$0")/../.." cd "$(dirname "$0")/../.."
python manage.py checkconfig python2.7 manage.py checkconfig
python manage.py migrate --noinput python2.7 manage.py migrate --noinput
python manage.py createcachetable third_party_api_results python2.7 manage.py createcachetable third_party_api_results
if ! python manage.py initialize_voyager_db; then if ! python2.7 manage.py initialize_voyager_db; then
set +x set +x
echo echo
echo -e "\033[32mPopulating default database failed." echo -e "\033[32mPopulating default database failed."

View File

@ -1,4 +1,4 @@
#!/usr/bin/python #!/usr/bin/env python2.7
import sys import sys
import subprocess import subprocess

View File

@ -65,7 +65,7 @@ to pull out the resulting HTML :)
</div> </div>
<div class="tab-pane" id="python"> <div class="tab-pane" id="python">
<div class="codehilite"><pre><span class="c">#!/usr/bin/env python</span> <div class="codehilite"><pre><span class="c">#!/usr/bin/env python2.7</span>
<span class="kn">import</span> <span class="nn">zulip</span> <span class="kn">import</span> <span class="nn">zulip</span>
<span class="kn">import</span> <span class="nn">sys</span> <span class="kn">import</span> <span class="nn">sys</span>

View File

@ -1,4 +1,4 @@
#!/usr/bin/env python #!/usr/bin/env python2.7
import os import os
import sys import sys
import subprocess import subprocess

View File

@ -1,4 +1,4 @@
#!/usr/bin/env python #!/usr/bin/env python2.7
from __future__ import absolute_import from __future__ import absolute_import
import os import os

View File

@ -1,4 +1,4 @@
#!/usr/bin/python #!/usr/bin/env python2.7
import datetime import datetime
import monthdelta import monthdelta

View File

@ -1,4 +1,4 @@
#!/usr/bin/env python #!/usr/bin/env python2.7
# #
# Generates % delta activity metrics from graphite/statsd data # Generates % delta activity metrics from graphite/statsd data
# #

View File

@ -1,4 +1,4 @@
#!/usr/bin/env python #!/usr/bin/env python2.7
# -*- coding: utf-8 -*- # -*- coding: utf-8 -*-
# Copyright © 2013 Zulip, Inc. # Copyright © 2013 Zulip, Inc.

View File

@ -1,4 +1,4 @@
#!/usr/bin/env python #!/usr/bin/env python2.7
# #
# This is tool for injecting messages during a usability study. It's # This is tool for injecting messages during a usability study. It's
# likely useless for other applications. # likely useless for other applications.

View File

@ -1,4 +1,4 @@
#!/usr/bin/env python #!/usr/bin/env python2.7
# encoding: utf-8 # encoding: utf-8
# #
# Copyright (C) 2010 Ksplice, Inc. # Copyright (C) 2010 Ksplice, Inc.

View File

@ -1,4 +1,4 @@
#!/usr/bin/env python #!/usr/bin/env python2.7
import os import os
import shutil import shutil
import subprocess import subprocess

View File

@ -1,4 +1,4 @@
#!/usr/bin/env python #!/usr/bin/env python2.7
import sys import sys
import re import re
import json import json

View File

@ -1,4 +1,4 @@
#!/usr/bin/env python #!/usr/bin/env python2.7
import os import os
import re import re
import sys import sys

View File

@ -1,4 +1,4 @@
#!/usr/bin/env python #!/usr/bin/env python2.7
# Minifies JavaScripts, creating source maps # Minifies JavaScripts, creating source maps

View File

@ -1,4 +1,4 @@
#!/usr/bin/env python #!/usr/bin/env python2.7
# #
# Zulip's post-receive hook. There is a symlink # Zulip's post-receive hook. There is a symlink
# from /home/git/repositories/eng/zulip.git/hooks/post-receive # from /home/git/repositories/eng/zulip.git/hooks/post-receive

View File

@ -1,4 +1,4 @@
#!/usr/bin/env python #!/usr/bin/env python2.7
import sh import sh
import os import os
import re import re

View File

@ -1,4 +1,4 @@
#!/usr/bin/env python #!/usr/bin/env python2.7
# -*- coding: cp1252 -*- # -*- coding: cp1252 -*-
# <PythonProxy.py> # <PythonProxy.py>
# #

View File

@ -1,4 +1,4 @@
#!/usr/bin/env python #!/usr/bin/env python2.7
# This script is only meant to be run from run-dev.py, which sets up the # This script is only meant to be run from run-dev.py, which sets up the
# environment correctly and passes the correct arguments for manage.py. It is a # environment correctly and passes the correct arguments for manage.py. It is a

Some files were not shown because too many files have changed in this diff Show More