-
Notifications
You must be signed in to change notification settings - Fork 12
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
1 parent
d8dde63
commit 3329f78
Showing
42 changed files
with
1,281 additions
and
802 deletions.
There are no files selected for viewing
This file was deleted.
Oops, something went wrong.
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
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,21 @@ | ||
# Root editor config file | ||
root = true | ||
|
||
# Common settings | ||
[*] | ||
end_of_line = lf | ||
insert_final_newline = true | ||
trim_trailing_whitespace = true | ||
charset = utf-8 | ||
|
||
# python, js indentation settings | ||
[{*.py,*.js,*.vue,*.css,*.scss,*.html}] | ||
indent_style = tab | ||
indent_size = 4 | ||
max_line_length = 99 | ||
|
||
# JSON files - mostly doctype schema files | ||
[{*.json}] | ||
insert_final_newline = false | ||
indent_style = space | ||
indent_size = 2 |
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
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,3 @@ | ||
shopify_integration/public/js/lib/* | ||
shopify_integration/templates/includes/* | ||
shopify_integration/www/website_script.js |
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
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,125 @@ | ||
{ | ||
"env": { | ||
"browser": true, | ||
"node": true, | ||
"es2022": true | ||
}, | ||
"parserOptions": { | ||
"sourceType": "module" | ||
}, | ||
"extends": "eslint:recommended", | ||
"rules": { | ||
"indent": "off", | ||
"brace-style": "off", | ||
"no-mixed-spaces-and-tabs": "off", | ||
"no-useless-escape": "off", | ||
"space-unary-ops": ["error", { "words": true }], | ||
"linebreak-style": "off", | ||
"quotes": ["off"], | ||
"semi": "off", | ||
"camelcase": "off", | ||
"no-unused-vars": "off", | ||
"no-console": ["warn"], | ||
"no-extra-boolean-cast": ["off"], | ||
"no-control-regex": ["off"] | ||
}, | ||
"root": true, | ||
"globals": { | ||
"frappe": true, | ||
"erpnext_integrations": true, | ||
"Vue": true, | ||
"SetVueGlobals": true, | ||
"__": true, | ||
"repl": true, | ||
"Class": true, | ||
"locals": true, | ||
"cint": true, | ||
"cstr": true, | ||
"cur_frm": true, | ||
"cur_dialog": true, | ||
"cur_page": true, | ||
"cur_list": true, | ||
"cur_tree": true, | ||
"msg_dialog": true, | ||
"is_null": true, | ||
"in_list": true, | ||
"has_common": true, | ||
"posthog": true, | ||
"has_words": true, | ||
"validate_email": true, | ||
"open_web_template_values_editor": true, | ||
"validate_name": true, | ||
"validate_phone": true, | ||
"validate_url": true, | ||
"get_number_format": true, | ||
"format_number": true, | ||
"format_currency": true, | ||
"comment_when": true, | ||
"open_url_post": true, | ||
"toTitle": true, | ||
"lstrip": true, | ||
"rstrip": true, | ||
"strip": true, | ||
"strip_html": true, | ||
"replace_all": true, | ||
"flt": true, | ||
"precision": true, | ||
"CREATE": true, | ||
"AMEND": true, | ||
"CANCEL": true, | ||
"copy_dict": true, | ||
"get_number_format_info": true, | ||
"strip_number_groups": true, | ||
"print_table": true, | ||
"Layout": true, | ||
"web_form_settings": true, | ||
"$c": true, | ||
"$a": true, | ||
"$i": true, | ||
"$bg": true, | ||
"$y": true, | ||
"$c_obj": true, | ||
"refresh_many": true, | ||
"refresh_field": true, | ||
"toggle_field": true, | ||
"get_field_obj": true, | ||
"get_query_params": true, | ||
"unhide_field": true, | ||
"hide_field": true, | ||
"set_field_options": true, | ||
"getCookie": true, | ||
"getCookies": true, | ||
"get_url_arg": true, | ||
"md5": true, | ||
"$": true, | ||
"jQuery": true, | ||
"moment": true, | ||
"hljs": true, | ||
"Awesomplete": true, | ||
"Sortable": true, | ||
"Showdown": true, | ||
"Taggle": true, | ||
"Gantt": true, | ||
"Slick": true, | ||
"Webcam": true, | ||
"PhotoSwipe": true, | ||
"PhotoSwipeUI_Default": true, | ||
"io": true, | ||
"JsBarcode": true, | ||
"L": true, | ||
"Chart": true, | ||
"DataTable": true, | ||
"Cypress": true, | ||
"cy": true, | ||
"it": true, | ||
"describe": true, | ||
"expect": true, | ||
"context": true, | ||
"before": true, | ||
"beforeEach": true, | ||
"after": true, | ||
"qz": true, | ||
"localforage": true, | ||
"extend_cscript": true | ||
} | ||
} |
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
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,75 @@ | ||
[flake8] | ||
ignore = | ||
B001, | ||
B007, | ||
B009, | ||
B010, | ||
B950, | ||
E101, | ||
E111, | ||
E114, | ||
E116, | ||
E117, | ||
E121, | ||
E122, | ||
E123, | ||
E124, | ||
E125, | ||
E126, | ||
E127, | ||
E128, | ||
E131, | ||
E201, | ||
E202, | ||
E203, | ||
E211, | ||
E221, | ||
E222, | ||
E223, | ||
E224, | ||
E225, | ||
E226, | ||
E228, | ||
E231, | ||
E241, | ||
E242, | ||
E251, | ||
E261, | ||
E262, | ||
E265, | ||
E266, | ||
E271, | ||
E272, | ||
E273, | ||
E274, | ||
E301, | ||
E302, | ||
E303, | ||
E305, | ||
E306, | ||
E402, | ||
E501, | ||
E502, | ||
E701, | ||
E702, | ||
E703, | ||
E741, | ||
F401, | ||
F403, | ||
F405, | ||
W191, | ||
W291, | ||
W292, | ||
W293, | ||
W391, | ||
W503, | ||
W504, | ||
E711, | ||
E129, | ||
F841, | ||
E713, | ||
E712, | ||
B028, | ||
|
||
max-line-length = 200 | ||
exclude=,test_*.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
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,49 @@ | ||
#!/bin/bash | ||
|
||
set -e | ||
|
||
cd ~ || exit | ||
|
||
sudo apt update | ||
sudo apt remove mysql-server mysql-client | ||
sudo apt install libcups2-dev redis-server mariadb-client-10.6 | ||
|
||
pip install frappe-bench | ||
|
||
git clone https://github.com/ParsimonyGit/frappe --branch "parsimony-production-v15" --depth 1 | ||
bench init --skip-assets --frappe-path ~/frappe --python "$(which python)" frappe-bench | ||
|
||
mkdir ~/frappe-bench/sites/test_site | ||
cp -r "${GITHUB_WORKSPACE}/.github/helper/site_config.json" ~/frappe-bench/sites/test_site/ | ||
|
||
mariadb --host 127.0.0.1 --port 3306 -u root -proot -e "SET GLOBAL character_set_server = 'utf8mb4'" | ||
mariadb --host 127.0.0.1 --port 3306 -u root -proot -e "SET GLOBAL collation_server = 'utf8mb4_unicode_ci'" | ||
mariadb --host 127.0.0.1 --port 3306 -u root -proot -e "CREATE USER 'test_frappe'@'localhost' IDENTIFIED BY 'test_frappe'" | ||
mariadb --host 127.0.0.1 --port 3306 -u root -proot -e "CREATE DATABASE test_frappe" | ||
mariadb --host 127.0.0.1 --port 3306 -u root -proot -e "GRANT ALL PRIVILEGES ON \`test_frappe\`.* TO 'test_frappe'@'localhost'" | ||
mariadb --host 127.0.0.1 --port 3306 -u root -proot -e "FLUSH PRIVILEGES" | ||
|
||
install_whktml() { | ||
wget -O /tmp/wkhtmltox.tar.xz https://github.com/frappe/wkhtmltopdf/raw/master/wkhtmltox-0.12.3_linux-generic-amd64.tar.xz | ||
tar -xf /tmp/wkhtmltox.tar.xz -C /tmp | ||
sudo mv /tmp/wkhtmltox/bin/wkhtmltopdf /usr/local/bin/wkhtmltopdf | ||
sudo chmod o+x /usr/local/bin/wkhtmltopdf | ||
} | ||
install_whktml & | ||
|
||
cd ~/frappe-bench || exit | ||
|
||
sed -i 's/watch:/# watch:/g' Procfile | ||
sed -i 's/schedule:/# schedule:/g' Procfile | ||
sed -i 's/socketio:/# socketio:/g' Procfile | ||
sed -i 's/redis_socketio:/# redis_socketio:/g' Procfile | ||
|
||
bench get-app https://github.com/ParsimonyGit/erpnext --branch "parsimony-production-v15" --resolve-deps | ||
bench get-app shopify_integration "${GITHUB_WORKSPACE}" | ||
bench setup requirements --dev | ||
|
||
bench start &> bench_run_logs.txt & | ||
CI=Yes bench build --app frappe & | ||
|
||
bench --site test_site reinstall --yes | ||
bench --site test_site install-app shopify_integration |
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
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,16 @@ | ||
{ | ||
"db_host": "127.0.0.1", | ||
"db_port": 3306, | ||
"db_name": "test_frappe", | ||
"db_password": "test_frappe", | ||
"auto_email_id": "[email protected]", | ||
"mail_server": "smtp.example.com", | ||
"mail_login": "[email protected]", | ||
"mail_password": "test", | ||
"admin_password": "admin", | ||
"root_login": "root", | ||
"root_password": "root", | ||
"host_name": "http://test_site:8000", | ||
"install_apps": ["erpnext", "shopify_integration"], | ||
"throttle_user_limit": 100 | ||
} |
Oops, something went wrong.