Skip to content
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

single file option for run doesn't work anymore #624

Closed
johnnyman727 opened this issue Mar 12, 2016 · 4 comments
Closed

single file option for run doesn't work anymore #624

johnnyman727 opened this issue Mar 12, 2016 · 4 comments
Assignees

Comments

@johnnyman727
Copy link
Contributor

I tried deploying just a single file (with the -s flag) and the CLI sent the entire bundle.

@rwaldron
Copy link
Contributor

I'm afraid our existing tests might not have been sufficient for this path 😠

I'll get this resolved asap.

@rwaldron rwaldron self-assigned this Mar 13, 2016
@rwaldron
Copy link
Contributor

When I tested this just now, only the single file was sent.

mkdir tessel-init; cd tessel-init; 
t2 init;
npm install math-euler;
echo "var Euler = require('math-euler');" > index.js;
t2 run index.js -s;

Result:

INFO Looking for your Tessel...
INFO Connected to bishop.
INFO Building project.
INFO Writing project to RAM on bishop (2.048 kB)...
INFO Deployed.
INFO Running index.js...
module.js:339
    throw err;
    ^

Error: Cannot find module 'math-euler'
    at Function.Module._resolveFilename (module.js:337:15)
    at Function.Module._load (module.js:287:25)
    at Module.require (module.js:366:17)
    at require (module.js:385:17)
    at Object.<anonymous> (/tmp/remote-script/index.js:1:69)
    at Module._compile (module.js:435:26)
    at Object.Module._extensions..js (module.js:442:10)
    at Module.load (module.js:356:32)
    at Function.Module._load (module.js:311:12)
    at Function.Module.runMain (module.js:467:10)

Confirmed by ssh to board:

$ ssh root@bishop.local -i ~/.tessel/id_rsa

BusyBox v1.23.2 (2015-12-16 06:42:04 UTC) built-in shell (ash)

Tessel 2  /  Built on OpenWrt
root@bishop:~# cd /tmp/remote-script/ && ls
index.js

@rwaldron
Copy link
Contributor

I did discover that -s isn't ignoring .tesselinclude matches.

@rwaldron
Copy link
Contributor

Also, binary modules are incorrectly included as well. Fix coming.

rwaldron added a commit to rwaldron/t2-cli that referenced this issue Mar 13, 2016
rwaldron added a commit that referenced this issue Mar 18, 2016
Ensure that .tesselinclude and binary modules are ignored when using -s flag. Fixes gh-624
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants