- Download docker-compose.yml to dir named
sentry
- Change
SENTRY_SECRET_KEY
to random 32 char string - Run
docker-compose up -d
- Run
docker-compose exec sentry sentry upgrade
to setup database and create admin user - (Optional) Run
docker-compose exec sentry pip install sentry-slack
if you want slack plugin, it can be done later - Run
docker-compose restart sentry
- Sentry is now running on public port
9000
View django_pagination_bootstrap4
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
{% if is_paginated %} | |
<nav aria-label="Page navigation example"> | |
<ul class="pagination justify-content-left"> | |
{% if page_obj.has_previous %} | |
<li class="page-item"><a class="page-link" href="?page={{ page_obj.previous_page_number }}">«</a></li> | |
{% else %} | |
<li class="page-item disabled"><a class="page-link" href="#"><span>«</span></a></li> | |
{% endif %} | |
{% for i in paginator.page_range %} | |
{% if page_obj.number == i %} |
View README.md
View secondsToText.py
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
def pluralizeRussian(number, nom_sing, gen_sing, gen_pl): | |
s_last_digit = str(number)[-1] | |
if int(str(number)[-2:]) in range(11,20): | |
#11-19 | |
return gen_pl | |
elif s_last_digit == '1': | |
#1 | |
return nom_sing | |
elif int(s_last_digit) in range(2,5): |
View curl.md
Common Options
-#, --progress-bar
Make curl display a simple progress bar instead of the more informational standard meter.
-b, --cookie <name=data>
Supply cookie with request. If no =
, then specifies the cookie file to use (see -c
).
-c, --cookie-jar <file name>
File to save response cookies to.
View Dictionary+Enum.swift
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
protocol StringEnum { | |
var rawValue: String { get } | |
} | |
extension Dictionary { | |
subscript(enumKey: StringEnum) -> Value? { | |
get { | |
if let key = enumKey.rawValue as? Key { | |
return self[key] | |
} |
View cx_oracle.md
First of all, it just seems like doing anything with Oracle is obnoxiously painful for no good reason. It's the nature of the beast I suppose. cx_oracle is a python module that allows you to connect to an Oracle Database and issue queries, inserts, updates..usual jazz.
Linux
Step 1:
sudo apt-get install build-essential unzip python-dev libaio-dev
Step 2. Click here to download the appropriate zip files required for this. You'll need: