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

Doesn't respect ---shadow #31

Closed
jasonkneen opened this issue Nov 11, 2014 · 12 comments
Closed

Doesn't respect ---shadow #31

jasonkneen opened this issue Nov 11, 2014 · 12 comments

Comments

@jasonkneen
Copy link
Owner

Created a recipe with --shadow in it, e.g:

--ios --shadow

and shadow is ignored

Add --shadow on the end so

ti devtest --shadow

and it works

@FokkeZB
Copy link
Collaborator

FokkeZB commented Nov 12, 2014

I can't reproduce with TiNy 2.1.1 and TiShadow 2.6.0:

≫ tn save b31 --ios --shadow

≫ ti b31
TiNy cooked: ti build --platform ios --shadow

≫ ti b31 --verbose
[DEBUG] Assumed build command: ti build --b31
[DEBUG] Cooking b31 recipe ..
[DEBUG]   Cooking ios recipe ..
[DEBUG]   .. into:  --platform ios --shadow
[DEBUG] .. into: build --platform ios --shadow
TiNy cooked: ti build --platform ios --shadow

@FokkeZB
Copy link
Collaborator

FokkeZB commented Nov 12, 2014

The actual problem is that @dbankier his init only inserts the hook if it finds --shadow in the arguments and if the TiNy init runs after TiShadow's, then these will not have --shadow yet:

function init(_logger, config, cli) {
  // users who are on the wrong SDK without this being set... TiShadow would just fail to work at all
  if (process.argv.indexOf('--shadow') !== -1 || process.argv.indexOf('--tishadow') !== -1) {
    cli.config.cli.failOnWrongSDK = true;
    cli.addHook('build.pre.compile', preCompileHook(true));
  } else if (process.argv.indexOf('--appify') !== -1) {
    cli.config.cli.failOnWrongSDK = true;
    cli.addHook('build.pre.compile', preCompileHook(false));
  }
  logger = _logger;
}

@jasonkneen
Copy link
Owner Author

Are you going through the complete meal or just having the starter? Tiny cooks it yes but the build doesn't work, and continues, ignoring tishadow which doesn't startup, unless it's  manually appended.

@FokkeZB
Copy link
Collaborator

FokkeZB commented Nov 12, 2014

See comments above. I'll ask @cb1kenobi if there's anything I can do to prioritise the init's running.

@jasonkneen
Copy link
Owner Author

As long as you can reproduce that's cool.

@FokkeZB
Copy link
Collaborator

FokkeZB commented Nov 12, 2014

I can

@FokkeZB
Copy link
Collaborator

FokkeZB commented Nov 12, 2014

According to @cb1kenobi the trick would be to make sure TiNy's path is before TiShadow's in Titanium's paths.hooks config. I'll update TiNy to make sure it does.

@jasonkneen
Copy link
Owner Author

Cool

On Wed, Nov 12, 2014 at 8:16 AM, Fokke Zandbergen
notifications@github.com wrote:

According to @cb1kenobi the trick would be to make sure TiNy's path is before TiShadow's in Titanium's paths.hooks config. I'll update TiNy to make sure it does.

Reply to this email directly or view it on GitHub:
#31 (comment)

@dbankier
Copy link
Contributor

TiShadow doesn't respond to the --shadow flag in unit anymore. That was an issue you raised and we fixed a while back. Not sure if that fix is published yet...

@dbankier
Copy link
Contributor

Unit===init

@FokkeZB
Copy link
Collaborator

FokkeZB commented Nov 14, 2014

@dbankier is right, it was fixed on August 20th:
dbankier/TiShadow@f69abe3

However, latest published version (2.6.0) is 4 months old.

@dbankier
Copy link
Contributor

right...

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

3 participants