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
.sc-jtRlXQ { | |
padding-left: 2.5rem; | |
} | |
/* background */ | |
.sc-fOICqy { | |
border-radius: 24px 16px 16px 16px; | |
border: 1px solid #fff; | |
margin-right: -1px; | |
margin-bottom: -1px; |
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
[package] | |
name = "hello_world" | |
version = "0.1.0" | |
edition = "2018" | |
[dependencies] | |
qt_core = "*" | |
qt_gui = "*" | |
qt_widgets = "*" |
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
#!/usr/bin/env sh | |
set -e | |
# Based on https://www.hozed.net/?p=538 | |
SSH_STRING="" | |
SSH_PORT="22" | |
# FYI: Assuming, that cert files are present and named: cert.key & cert.cert | |
scp -P $SSH_PORT cert.key $SSH_STRING:/etc/stunnel/backup.key &>/dev/null |
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
#!/usr/bin/env sh | |
# Based on https://forum.netgate.com/post/785981 | |
HOSTNAME="" | |
CERT_ID="" | |
USERNAME="" | |
PASSWORD="" | |
echo "Downloading certificate id=${CERT_ID} from ${HOSTNAME} into cert.pem file..." |
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
#!/usr/bin/env bash | |
tarBranch=$(git branch -r --merged | grep -v master | grep -v develop | sed 's/origin\///') | |
for branch in $tarBranch | |
do | |
echo "Branch: $branch" | |
lastDate=$(git show -s --format=%ci origin/$branch) | |
convertDate=$(echo $lastDate | cut -d' ' -f 1) | |
Todate=$(date -d "$convertDate" +'%s') | |
current=$(date +'%s') |
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
# https://stackoverflow.com/a/35428134 | |
def _counter(d): | |
# how many keys do we have? | |
yield len(d) | |
# stream the key counts of our children | |
for v in iter(d.values()): | |
if isinstance(v, dict): |
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
""" | |
csv exporter | |
~~~~~ | |
Usage: | |
* in your admin class for model, insert: actions = [ download_as_csv_view ] | |
* add columns names in HEADER | |
* add data columns in _make_csv_row | |
:copyright: (c) https://github.com/danie1k |
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
SET FOREIGN_KEY_CHECKS=0; | |
TRUNCATE `sales_flat_creditmemo`; | |
TRUNCATE `sales_flat_creditmemo_comment`; | |
TRUNCATE `sales_flat_creditmemo_grid`; | |
TRUNCATE `sales_flat_creditmemo_item`; | |
TRUNCATE `sales_flat_invoice`; | |
TRUNCATE `sales_flat_invoice_comment`; | |
TRUNCATE `sales_flat_invoice_grid`; | |
TRUNCATE `sales_flat_invoice_item`; | |
TRUNCATE `sales_flat_order`; |
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
SET FOREIGN_KEY_CHECKS = 0; | |
TRUNCATE TABLE `catalog_product_bundle_option`; | |
TRUNCATE TABLE `catalog_product_bundle_option_value`; | |
TRUNCATE TABLE `catalog_product_bundle_selection`; | |
TRUNCATE TABLE `catalog_product_entity_datetime`; | |
TRUNCATE TABLE `catalog_product_entity_decimal`; | |
TRUNCATE TABLE `catalog_product_entity_gallery`; | |
TRUNCATE TABLE `catalog_product_entity_int`; | |
TRUNCATE TABLE `catalog_product_entity_media_gallery`; | |
TRUNCATE TABLE `catalog_product_entity_media_gallery_value`; |
NewerOlder