Skip to content

Instantly share code, notes, and snippets.

View SButko's full-sized avatar

Silvija Butko SButko

View GitHub Profile
@CristinaSolana
CristinaSolana / gist:1885435
Created February 22, 2012 14:56
Keeping a fork up to date

1. Clone your fork:

git clone git@github.com:YOUR-USERNAME/YOUR-FORKED-REPO.git

2. Add remote from original repository in your forked repository:

cd into/cloned/fork-repo
git remote add upstream git://github.com/ORIGINAL-DEV-USERNAME/REPO-YOU-FORKED-FROM.git
git fetch upstream
@oerp-odoo
oerp-odoo / recompute_odoo_field.py
Last active August 11, 2018 11:36
Recompute Odoo field from shell
# python3 odoo-bin shell -c odoo.conf -d <database>
model = env['some.model']
env.add_todo(model._fields['field_name'], model.search([]))
model.recompute()
env.cr.commit()
@SButko
SButko / recompute_odoo_field
Created August 10, 2018 20:17 — forked from oerp-odoo/recompute_odoo_field.py
Recompute Odoo field from shell
# python3 odoo-bin shell -c odoo.conf -d <database>
model = env['some.model']
env.add_todo(model._fields['field_name'], model.search([]))
model.recompute()
env.cr.commit()