question-mark
Stuck on an issue?

Lightrun Answers was designed to reduce the constant googling that comes with debugging 3rd party libraries. It collects links to all the places you might be looking at while hunting down a tough bug.

And, if you’re still stuck at the end, we’re happy to hop on a call to see how we can help out.

[feature-request] Handle flag parameters case insensitive

See original GitHub issue

I’m submitting a feature request

  • Library Version: 0.30.1

Please tell us about your environment:

  • Operating System: Windows 10

  • Node Version: 8.1.1

  • NPM Version: 4.0.3

  • Browser: n.a.

  • Language: all

Current behavior: When performing a build using the command

au build --env Prod

it seems to run a dev build ( because of the capital P).

Expected/desired behavior: Perform a build for the prod environment, just like au build --env prod would do

  • What is the expected behavior? It would be cool if it could handle flags case insensitive.

  • What is the motivation / use case for changing the behavior? Just discovered that our build in TFS was setup this way and it didn’t generate revisions / use cache busting. Modified it to lowercase, but it might be something other users of Aurelia experience as well. It might be more friendly to just always lowercase the params (if that is possible for all use cases).

Issue Analytics

  • State:closed
  • Created 6 years ago
  • Comments:7 (7 by maintainers)

github_iconTop GitHub Comments

3reactions
zewa666commented, Aug 30, 2017

What about keeping it as it is, but additionally logging a warning that the provided env could not be located and the build task falls back to dev?

1reaction
erikliebencommented, Aug 31, 2017

Ah didn’t know that 😃 A warning sounds great to quicker see what’s going wrong and give users more information about what’s going on 👍

I do wonder if only a warning enough for this specific case?

By default it is used in dev mode, so the cases where you would use this specific command is either in a production, acceptance or staging build right?

Is it a better option to halt/error the complete process in this case? So the build fails in this case? I am not sure if this is the responsibility of the CLI or the developer (if there should be some other process in place to handle this: for example some integration test case that runs before the actual deployment or a manual check).

As an example when this might occur as an issue is in the following case:

  • If you use a build server/ CI that automatically deploys to production using au build --env prod.
  • For some reason the prod.json could not be accessed / or is not available during build.
  • A warning shows in the CI build log
  • The deployment is build for dev (default) and is automatically deployed to a production slot.

Not sure if this is an actual use case, might depend upon how well structured your deployment process is.

Or do many CI tools halt on warnings in the command line? because as far as I know visual studio online build just ignores them, it will only break the build if you thow errors in the console.

Read more comments on GitHub >

github_iconTop Results From Across the Web

Consider optional case insensitive parsing · Issue #133
I suspect this would need to be handled in a similar manner to an existing parse error, with some message indicating that it...
Read more >
MongoDB: Is it possible to make a case-insensitive query?
Here's how it works: A case-insensitive index is made by specifying a collation with a strength of either 1 or 2. You can...
Read more >
Using the Linux kernel's Case-insensitive feature in Ext4
An individual create/open can, if a flag is set in the operation, be performed case sensitively. It's fairly easy if things are stored...
Read more >
Collations and case sensitivity - EF Core
Configuring collations and case-sensitivity in the database and on queries with Entity Framework Core.
Read more >
Linguistic Sorting and Matching
This chapter explains the mechanism of linguistic sorting and searching of character data or strings in Oracle Database. The process of determining the ......
Read more >

github_iconTop Related Medium Post

No results found

github_iconTop Related StackOverflow Question

No results found

github_iconTroubleshoot Live Code

Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start Free

github_iconTop Related Reddit Thread

No results found

github_iconTop Related Hackernoon Post

No results found

github_iconTop Related Tweet

No results found

github_iconTop Related Dev.to Post

No results found

github_iconTop Related Hashnode Post

No results found