-
Notifications
You must be signed in to change notification settings - Fork 679
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Improve Js2C converter #1408
Improve Js2C converter #1408
Conversation
@@ -122,7 +127,7 @@ def exportOneFile(path, name): | |||
def exportOneName(name): | |||
writeLine(fout, '{ ' + name + '_n, ' + name + '_s, ' + name + '_l }, \\', 1) | |||
|
|||
files = glob.glob(SRC_PATH + '*.js') | |||
files = glob.glob(SRC_PATH + '/*.js') |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
This could also be joined (os.path.join) together.
OUT_PATH = './source/' | ||
SRC_PATH = './js/' | ||
OUT_PATH = './source' | ||
SRC_PATH = './js' |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I see no point having this, just move them into the add_argument call.
|
||
import argparse | ||
from os import path |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
We could simply use: os.path.join
then there is no need for this import :)
4bc953f
to
42e5ce1
Compare
@galpeter, thanks for the review. I've updated the PR. |
* Rename 'jerry_targetjs.h' to 'jerry-targetjs.h', because we use dashes in filen ames instead of underscores. * Made destination and js souce directory configurable. * Updated esp8266 target to the recent changes. * Updated mbed and mbedos5 target to the recent changes. JerryScript-DCO-1.0-Signed-off-by: László Langó llango.u-szeged@partner.samsung.com
42e5ce1
to
b23b991
Compare
LGTM |
1 similar comment
LGTM |
because we use dashes in file names instead of underscores.
JerryScript-DCO-1.0-Signed-off-by: László Langó llango.u-szeged@partner.samsung.com