website
This commit is contained in:
51
website/web/Scripts/Activate.ps1
Normal file
51
website/web/Scripts/Activate.ps1
Normal file
@ -0,0 +1,51 @@
|
||||
function global:deactivate ([switch]$NonDestructive) {
|
||||
# Revert to original values
|
||||
if (Test-Path function:_OLD_VIRTUAL_PROMPT) {
|
||||
copy-item function:_OLD_VIRTUAL_PROMPT function:prompt
|
||||
remove-item function:_OLD_VIRTUAL_PROMPT
|
||||
}
|
||||
|
||||
if (Test-Path env:_OLD_VIRTUAL_PYTHONHOME) {
|
||||
copy-item env:_OLD_VIRTUAL_PYTHONHOME env:PYTHONHOME
|
||||
remove-item env:_OLD_VIRTUAL_PYTHONHOME
|
||||
}
|
||||
|
||||
if (Test-Path env:_OLD_VIRTUAL_PATH) {
|
||||
copy-item env:_OLD_VIRTUAL_PATH env:PATH
|
||||
remove-item env:_OLD_VIRTUAL_PATH
|
||||
}
|
||||
|
||||
if (Test-Path env:VIRTUAL_ENV) {
|
||||
remove-item env:VIRTUAL_ENV
|
||||
}
|
||||
|
||||
if (!$NonDestructive) {
|
||||
# Self destruct!
|
||||
remove-item function:deactivate
|
||||
}
|
||||
}
|
||||
|
||||
deactivate -nondestructive
|
||||
|
||||
$env:VIRTUAL_ENV="R:\github\website\web"
|
||||
|
||||
if (! $env:VIRTUAL_ENV_DISABLE_PROMPT) {
|
||||
# Set the prompt to include the env name
|
||||
# Make sure _OLD_VIRTUAL_PROMPT is global
|
||||
function global:_OLD_VIRTUAL_PROMPT {""}
|
||||
copy-item function:prompt function:_OLD_VIRTUAL_PROMPT
|
||||
function global:prompt {
|
||||
Write-Host -NoNewline -ForegroundColor Green '(web) '
|
||||
_OLD_VIRTUAL_PROMPT
|
||||
}
|
||||
}
|
||||
|
||||
# Clear PYTHONHOME
|
||||
if (Test-Path env:PYTHONHOME) {
|
||||
copy-item env:PYTHONHOME env:_OLD_VIRTUAL_PYTHONHOME
|
||||
remove-item env:PYTHONHOME
|
||||
}
|
||||
|
||||
# Add the venv to the PATH
|
||||
copy-item env:PATH env:_OLD_VIRTUAL_PATH
|
||||
$env:PATH = "$env:VIRTUAL_ENV\Scripts;$env:PATH"
|
||||
BIN
website/web/Scripts/_asyncio.pyd
Normal file
BIN
website/web/Scripts/_asyncio.pyd
Normal file
Binary file not shown.
BIN
website/web/Scripts/_bz2.pyd
Normal file
BIN
website/web/Scripts/_bz2.pyd
Normal file
Binary file not shown.
BIN
website/web/Scripts/_ctypes.pyd
Normal file
BIN
website/web/Scripts/_ctypes.pyd
Normal file
Binary file not shown.
BIN
website/web/Scripts/_ctypes_test.pyd
Normal file
BIN
website/web/Scripts/_ctypes_test.pyd
Normal file
Binary file not shown.
BIN
website/web/Scripts/_decimal.pyd
Normal file
BIN
website/web/Scripts/_decimal.pyd
Normal file
Binary file not shown.
BIN
website/web/Scripts/_elementtree.pyd
Normal file
BIN
website/web/Scripts/_elementtree.pyd
Normal file
Binary file not shown.
BIN
website/web/Scripts/_hashlib.pyd
Normal file
BIN
website/web/Scripts/_hashlib.pyd
Normal file
Binary file not shown.
BIN
website/web/Scripts/_lzma.pyd
Normal file
BIN
website/web/Scripts/_lzma.pyd
Normal file
Binary file not shown.
BIN
website/web/Scripts/_msi.pyd
Normal file
BIN
website/web/Scripts/_msi.pyd
Normal file
Binary file not shown.
BIN
website/web/Scripts/_multiprocessing.pyd
Normal file
BIN
website/web/Scripts/_multiprocessing.pyd
Normal file
Binary file not shown.
BIN
website/web/Scripts/_overlapped.pyd
Normal file
BIN
website/web/Scripts/_overlapped.pyd
Normal file
Binary file not shown.
BIN
website/web/Scripts/_socket.pyd
Normal file
BIN
website/web/Scripts/_socket.pyd
Normal file
Binary file not shown.
BIN
website/web/Scripts/_sqlite3.pyd
Normal file
BIN
website/web/Scripts/_sqlite3.pyd
Normal file
Binary file not shown.
BIN
website/web/Scripts/_ssl.pyd
Normal file
BIN
website/web/Scripts/_ssl.pyd
Normal file
Binary file not shown.
BIN
website/web/Scripts/_testbuffer.pyd
Normal file
BIN
website/web/Scripts/_testbuffer.pyd
Normal file
Binary file not shown.
BIN
website/web/Scripts/_testcapi.pyd
Normal file
BIN
website/web/Scripts/_testcapi.pyd
Normal file
Binary file not shown.
BIN
website/web/Scripts/_testconsole.pyd
Normal file
BIN
website/web/Scripts/_testconsole.pyd
Normal file
Binary file not shown.
BIN
website/web/Scripts/_testimportmultiple.pyd
Normal file
BIN
website/web/Scripts/_testimportmultiple.pyd
Normal file
Binary file not shown.
BIN
website/web/Scripts/_testmultiphase.pyd
Normal file
BIN
website/web/Scripts/_testmultiphase.pyd
Normal file
Binary file not shown.
BIN
website/web/Scripts/_tkinter.pyd
Normal file
BIN
website/web/Scripts/_tkinter.pyd
Normal file
Binary file not shown.
76
website/web/Scripts/activate
Normal file
76
website/web/Scripts/activate
Normal file
@ -0,0 +1,76 @@
|
||||
# This file must be used with "source bin/activate" *from bash*
|
||||
# you cannot run it directly
|
||||
|
||||
deactivate () {
|
||||
# reset old environment variables
|
||||
if [ -n "$_OLD_VIRTUAL_PATH" ] ; then
|
||||
PATH="$_OLD_VIRTUAL_PATH"
|
||||
export PATH
|
||||
unset _OLD_VIRTUAL_PATH
|
||||
fi
|
||||
if [ -n "$_OLD_VIRTUAL_PYTHONHOME" ] ; then
|
||||
PYTHONHOME="$_OLD_VIRTUAL_PYTHONHOME"
|
||||
export PYTHONHOME
|
||||
unset _OLD_VIRTUAL_PYTHONHOME
|
||||
fi
|
||||
|
||||
# This should detect bash and zsh, which have a hash command that must
|
||||
# be called to get it to forget past commands. Without forgetting
|
||||
# past commands the $PATH changes we made may not be respected
|
||||
if [ -n "$BASH" -o -n "$ZSH_VERSION" ] ; then
|
||||
hash -r
|
||||
fi
|
||||
|
||||
if [ -n "$_OLD_VIRTUAL_PS1" ] ; then
|
||||
PS1="$_OLD_VIRTUAL_PS1"
|
||||
export PS1
|
||||
unset _OLD_VIRTUAL_PS1
|
||||
fi
|
||||
|
||||
unset VIRTUAL_ENV
|
||||
if [ ! "$1" = "nondestructive" ] ; then
|
||||
# Self destruct!
|
||||
unset -f deactivate
|
||||
fi
|
||||
}
|
||||
|
||||
# unset irrelevant variables
|
||||
deactivate nondestructive
|
||||
|
||||
VIRTUAL_ENV="R:\github\website\web"
|
||||
export VIRTUAL_ENV
|
||||
|
||||
_OLD_VIRTUAL_PATH="$PATH"
|
||||
PATH="$VIRTUAL_ENV/Scripts:$PATH"
|
||||
export PATH
|
||||
|
||||
# unset PYTHONHOME if set
|
||||
# this will fail if PYTHONHOME is set to the empty string (which is bad anyway)
|
||||
# could use `if (set -u; : $PYTHONHOME) ;` in bash
|
||||
if [ -n "$PYTHONHOME" ] ; then
|
||||
_OLD_VIRTUAL_PYTHONHOME="$PYTHONHOME"
|
||||
unset PYTHONHOME
|
||||
fi
|
||||
|
||||
if [ -z "$VIRTUAL_ENV_DISABLE_PROMPT" ] ; then
|
||||
_OLD_VIRTUAL_PS1="$PS1"
|
||||
if [ "x(web) " != x ] ; then
|
||||
PS1="(web) $PS1"
|
||||
else
|
||||
if [ "`basename \"$VIRTUAL_ENV\"`" = "__" ] ; then
|
||||
# special case for Aspen magic directories
|
||||
# see http://www.zetadev.com/software/aspen/
|
||||
PS1="[`basename \`dirname \"$VIRTUAL_ENV\"\``] $PS1"
|
||||
else
|
||||
PS1="(`basename \"$VIRTUAL_ENV\"`)$PS1"
|
||||
fi
|
||||
fi
|
||||
export PS1
|
||||
fi
|
||||
|
||||
# This should detect bash and zsh, which have a hash command that must
|
||||
# be called to get it to forget past commands. Without forgetting
|
||||
# past commands the $PATH changes we made may not be respected
|
||||
if [ -n "$BASH" -o -n "$ZSH_VERSION" ] ; then
|
||||
hash -r
|
||||
fi
|
||||
32
website/web/Scripts/activate.bat
Normal file
32
website/web/Scripts/activate.bat
Normal file
@ -0,0 +1,32 @@
|
||||
@echo off
|
||||
set "VIRTUAL_ENV=R:\github\website\web"
|
||||
|
||||
if not defined PROMPT (
|
||||
set "PROMPT=$P$G"
|
||||
)
|
||||
|
||||
if defined _OLD_VIRTUAL_PROMPT (
|
||||
set "PROMPT=%_OLD_VIRTUAL_PROMPT%"
|
||||
)
|
||||
|
||||
if defined _OLD_VIRTUAL_PYTHONHOME (
|
||||
set "PYTHONHOME=%_OLD_VIRTUAL_PYTHONHOME%"
|
||||
)
|
||||
|
||||
set "_OLD_VIRTUAL_PROMPT=%PROMPT%"
|
||||
set "PROMPT=(web) %PROMPT%"
|
||||
|
||||
if defined PYTHONHOME (
|
||||
set "_OLD_VIRTUAL_PYTHONHOME=%PYTHONHOME%"
|
||||
set PYTHONHOME=
|
||||
)
|
||||
|
||||
if defined _OLD_VIRTUAL_PATH (
|
||||
set "PATH=%_OLD_VIRTUAL_PATH%"
|
||||
) else (
|
||||
set "_OLD_VIRTUAL_PATH=%PATH%"
|
||||
)
|
||||
|
||||
set "PATH=%VIRTUAL_ENV%\Scripts;%PATH%"
|
||||
|
||||
:END
|
||||
21
website/web/Scripts/deactivate.bat
Normal file
21
website/web/Scripts/deactivate.bat
Normal file
@ -0,0 +1,21 @@
|
||||
@echo off
|
||||
|
||||
if defined _OLD_VIRTUAL_PROMPT (
|
||||
set "PROMPT=%_OLD_VIRTUAL_PROMPT%"
|
||||
)
|
||||
set _OLD_VIRTUAL_PROMPT=
|
||||
|
||||
if defined _OLD_VIRTUAL_PYTHONHOME (
|
||||
set "PYTHONHOME=%_OLD_VIRTUAL_PYTHONHOME%"
|
||||
set _OLD_VIRTUAL_PYTHONHOME=
|
||||
)
|
||||
|
||||
if defined _OLD_VIRTUAL_PATH (
|
||||
set "PATH=%_OLD_VIRTUAL_PATH%"
|
||||
)
|
||||
|
||||
set _OLD_VIRTUAL_PATH=
|
||||
|
||||
set VIRTUAL_ENV=
|
||||
|
||||
:END
|
||||
BIN
website/web/Scripts/easy_install-3.6.exe
Normal file
BIN
website/web/Scripts/easy_install-3.6.exe
Normal file
Binary file not shown.
BIN
website/web/Scripts/easy_install.exe
Normal file
BIN
website/web/Scripts/easy_install.exe
Normal file
Binary file not shown.
BIN
website/web/Scripts/flask.exe
Normal file
BIN
website/web/Scripts/flask.exe
Normal file
Binary file not shown.
BIN
website/web/Scripts/gunicorn.exe
Normal file
BIN
website/web/Scripts/gunicorn.exe
Normal file
Binary file not shown.
BIN
website/web/Scripts/gunicorn_paster.exe
Normal file
BIN
website/web/Scripts/gunicorn_paster.exe
Normal file
Binary file not shown.
74
website/web/Scripts/misaka
Normal file
74
website/web/Scripts/misaka
Normal file
@ -0,0 +1,74 @@
|
||||
#!r:\github\website\web\scripts\python3.exe
|
||||
|
||||
import sys
|
||||
from os import path
|
||||
|
||||
from misaka import *
|
||||
from misaka.utils import extension_map, html_flag_map
|
||||
|
||||
|
||||
help = '''\
|
||||
Usage: misaka [--ext-<extension>...] [--html-<flag>...] [--smartypants] [<file>...]
|
||||
|
||||
Parser extensions:
|
||||
{}
|
||||
|
||||
Render flags:
|
||||
{}
|
||||
|
||||
Other options:
|
||||
--smartypants
|
||||
-h | --help
|
||||
'''.format(
|
||||
'\n'.join([' --ext-' + a for a in extension_map.keys()]),
|
||||
'\n'.join([' --html-' + a for a in html_flag_map.keys()]))
|
||||
|
||||
|
||||
if __name__ == '__main__':
|
||||
args = sys.argv[1:]
|
||||
|
||||
files = []
|
||||
flags = []
|
||||
extensions = []
|
||||
pants_enabled = False
|
||||
|
||||
for arg in args:
|
||||
if arg in ('-h', '--help'):
|
||||
print(help)
|
||||
sys.exit(0)
|
||||
elif arg == '--smartypants':
|
||||
pants_enabled = True
|
||||
elif arg.startswith('--ext-'):
|
||||
arg = arg[6:]
|
||||
if not arg in extension_map:
|
||||
print('--ext-{0} is not a valid Markdown extension'.format(arg))
|
||||
sys.exit(1)
|
||||
extensions.append(arg)
|
||||
elif arg.startswith('--html-'):
|
||||
arg = arg[7:]
|
||||
if not arg in html_flag_map:
|
||||
print('--html-{0} is not a valid HTML render flag'.format(arg))
|
||||
sys.exit(1)
|
||||
flags.append(arg)
|
||||
else:
|
||||
# If it's not a extension or HTML flag,
|
||||
# then it must be a file, right?
|
||||
files.append(arg)
|
||||
|
||||
renderer = HtmlRenderer(flags)
|
||||
if pants_enabled:
|
||||
to_html = lambda n: smartypants(Markdown(renderer, extensions)(n))
|
||||
else:
|
||||
to_html = Markdown(renderer, extensions)
|
||||
|
||||
if files:
|
||||
for fn in files:
|
||||
fn = path.abspath(fn)
|
||||
if not path.exists(fn):
|
||||
print('Does not exist: %s' % fn)
|
||||
else:
|
||||
with open(fn, 'r') as fd:
|
||||
source = fd.read()
|
||||
print(to_html(source))
|
||||
else:
|
||||
print(to_html(sys.stdin.read()))
|
||||
BIN
website/web/Scripts/pip.exe
Normal file
BIN
website/web/Scripts/pip.exe
Normal file
Binary file not shown.
BIN
website/web/Scripts/pip3.6.exe
Normal file
BIN
website/web/Scripts/pip3.6.exe
Normal file
Binary file not shown.
BIN
website/web/Scripts/pip3.exe
Normal file
BIN
website/web/Scripts/pip3.exe
Normal file
Binary file not shown.
BIN
website/web/Scripts/pyexpat.pyd
Normal file
BIN
website/web/Scripts/pyexpat.pyd
Normal file
Binary file not shown.
BIN
website/web/Scripts/python.exe
Normal file
BIN
website/web/Scripts/python.exe
Normal file
Binary file not shown.
BIN
website/web/Scripts/python3.dll
Normal file
BIN
website/web/Scripts/python3.dll
Normal file
Binary file not shown.
BIN
website/web/Scripts/python3.exe
Normal file
BIN
website/web/Scripts/python3.exe
Normal file
Binary file not shown.
BIN
website/web/Scripts/python36.dll
Normal file
BIN
website/web/Scripts/python36.dll
Normal file
Binary file not shown.
BIN
website/web/Scripts/pythonw.exe
Normal file
BIN
website/web/Scripts/pythonw.exe
Normal file
Binary file not shown.
BIN
website/web/Scripts/select.pyd
Normal file
BIN
website/web/Scripts/select.pyd
Normal file
Binary file not shown.
BIN
website/web/Scripts/sqlite3.dll
Normal file
BIN
website/web/Scripts/sqlite3.dll
Normal file
Binary file not shown.
BIN
website/web/Scripts/tcl86t.dll
Normal file
BIN
website/web/Scripts/tcl86t.dll
Normal file
Binary file not shown.
BIN
website/web/Scripts/tk86t.dll
Normal file
BIN
website/web/Scripts/tk86t.dll
Normal file
Binary file not shown.
BIN
website/web/Scripts/unicodedata.pyd
Normal file
BIN
website/web/Scripts/unicodedata.pyd
Normal file
Binary file not shown.
BIN
website/web/Scripts/vcruntime140.dll
Normal file
BIN
website/web/Scripts/vcruntime140.dll
Normal file
Binary file not shown.
BIN
website/web/Scripts/winsound.pyd
Normal file
BIN
website/web/Scripts/winsound.pyd
Normal file
Binary file not shown.
Reference in New Issue
Block a user