Skip to content

Instantly share code, notes, and snippets.

Amirhossein Aleyasen Aleyasen

Block or report user

Report or block Aleyasen

Hide content and notifications from this user.

Learn more about blocking users

Contact Support about this user’s behavior.

Learn more about reporting abuse

Report abuse
View GitHub Profile
( SELECT current_database()::character varying(128) AS table_catalog, nc.nspname::character varying(128) AS table_schema, c.relname::character varying(128) AS table_name, a.attname::character varying(128) AS column_name, a.attnum::integer AS ordinal_position,
WHEN u.usename = "current_user"()::name THEN ad.adsrc::character varying(4000)
ELSE NULL::character varying::character varying(4000)
END AS column_default,
WHEN a.attnotnull OR t.typtype = 'd'::"char" AND t.typnotnull THEN 'NO'::character varying
ELSE 'YES'::character varying
END AS is_nullable,
Aleyasen /
Last active Jan 28, 2019
Use Github API to make daily Github administration routines much easier! (especially if you/your company has a lot of repositories)

You need ( and JQ ( to use these snippets.

  • Delete a collaborator from all of your repositories (e.g. in case a developer left the company) -j list_repos | jq -r -c '.[] | "\(.full_name)"' | xargs -I % sh -c './ -y delete_collaborator % [USERNAME]'
View docker exec ...
docker run \
> -d \
> -p 80:80 \
> --name saas-nginx \
> --network=odoo-saas \
> -t itprojectsllc/docker-odoo-nginx
Unable to find image 'itprojectsllc/docker-odoo-nginx:latest' locally
latest: Pulling from itprojectsllc/docker-odoo-nginx
43c265008fae: Pull complete
e4c030a565b1: Pull complete
View gist:3dd9559dd5ca22cd5f73c6765ccf0326
addons_path = /mnt/odoo-source/odoo/addons,/mnt/odoo-source/addons,/mnt/addons/OCA/account-closing,/mnt/addons/OCA/account-financial-reporting,/mnt/addons/OCA/account-financial-tools,/mnt/addons/OCA/account-invoicing,/mnt/addons/OCA/bank-payment,/mnt/addons/OCA/bank-statement-import,/mnt/addons/OCA/bank-statement-reconcile,/mnt/addons/OCA/commission,/mnt/addons/OCA/contract,/mnt/addons/OCA/event,/mnt/addons/OCA/hr,/mnt/addons/OCA/partner-contact,/mnt/addons/OCA/pos,/mnt/addons/OCA/reporting-engine,/mnt/addons/OCA/rma,/mnt/addons/OCA/sale-workflow,/mnt/addons/OCA/server-tools,/mnt/addons/OCA/web,/mnt/addons/OCA/website,/mnt/addons/it-projects-llc/access-addons,/mnt/addons/it-projects-llc/e-commerce,/mnt/addons/it-projects-llc/mail-addons,/mnt/addons/it-projects-llc/misc-addons,/mnt/addons/it-projects-llc/odoo-saas-tools,/mnt/addons/it-projects-llc/odoo-telegram,/mnt/addons/it-projects-llc/pos-addons,/mnt/addons/it-projects-llc/website-addons
admin_passwd = admin
dbfilter = ^%d$
View gist:677ef0b26a4d7118997919439d3ee2bd
import regex as re
import string
def translate_non_alphanumerics(to_translate, translate_to=u'_'):
not_letters_or_digits = u'!"#%\'()*+,-./:;<=>?@[\]^_`{|}~٫،؛'
translate_table = dict((ord(char), translate_to) for char in not_letters_or_digits)
return to_translate.translate(translate_table)
Aleyasen /
Created Aug 6, 2017 — forked from anttilipp/
Code to reproduce the "Temperature Circle" visualization.
# Hi all,
# this is the Python code I used to make the visualization "Temperature circle"
# (
# Please be aware that originally I wrote this for my tests only so the
# code was not ment to be published and is a mess and has no comments.
# Feel free to improve, modify, do whatever you want with it. If you decide
# to use the code, make an improved version of it, or it is useful for you
# in some another way I would be happy to know about it. You can contact me
# for example in Twitter (@anttilip). Unchecked demo data (no quarantees)
View error.log
jquery.js:3855 Uncaught Error: [$injector:modulerr] Failed to instantiate module fuse due to:
Error: [$injector:modulerr] Failed to instantiate module elasticsearch due to:
Error: [$injector:nomod] Module 'elasticsearch' is not available! You either misspelled the module name or forgot to load it. If registering a module ensure that you specify the dependencies as the second argument.$injector/nomod?p0=elasticsearch
at http://localhost:3000/bower_components/angular/angular.js:66:12
at http://localhost:3000/bower_components/angular/angular.js:2262:17
at ensure (http://localhost:3000/bower_components/angular/angular.js:2183:38)
at module (http://localhost:3000/bower_components/angular/angular.js:2260:14)
at http://localhost:3000/bower_components/angular/angular.js:4896:22
at forEach (http://localhost:3000/bower_components/angular/angular.js:403:20)
View e-commerce.module.js
'use strict';
// 3rd Party Dependencies
View index.module.js
(function ()
'use strict';
* Main module of the Fuse
.module('fuse', [
Aleyasen / visallo_error.log
Created Jul 7, 2016
Visallo installation "npm install" error
View visallo_error.log
[INFO] │ │ │ │ ├── ansi@0.3.1
[INFO] │ │ │ │ ├─┬ are-we-there-yet@1.1.2
[INFO] │ │ │ │ │ └── delegates@1.0.0
[INFO] │ │ │ │ └─┬ gauge@1.2.7
[INFO] │ │ │ │ ├── has-unicode@2.0.0
[INFO] │ │ │ │ ├─┬ lodash.pad@4.1.0
[INFO] │ │ │ │ │ ├── lodash.repeat@4.0.0
[INFO] │ │ │ │ │ └── lodash.tostring@4.1.2
[INFO] │ │ │ │ ├── lodash.padend@4.2.0
[INFO] │ │ │ │ └── lodash.padstart@4.2.0
You can’t perform that action at this time.