Commit Graph
208 Commits
Author SHA1 Message Date
Xavier Noria 554971c613 Use heredocs for top-level executables' usage docs (#9143) 2019-06-15 18:22:57 +02:00
José Valim 579c235a6f Allow to dry run the Elixir CLI command 2019-04-02 23:19:24 +02:00
José Valim a5395fc374 Add eval and version commands to releases (#8758)
We also split start | daemon iex | elixir into start and start_iex,
daemon and daemon_iex.
2019-02-02 21:27:28 +01:00
José Valim ceaa0450ce Shellcheck bin/elixirc too 2019-02-02 00:05:51 +01:00
José Valim d3aebdb6a5 Shellcheck improvements to bin/iex 2019-02-01 10:39:09 +01:00
Eksperimental bacda57b33 Make bin/elixir POSIX compliant (#8736)
We use Shellcheck as a linter
https://github.com/koalaman/shellcheck
2019-01-30 19:42:01 +01:00
José Valim 0eff63b349 Fix OS assertion on Elixir script 2019-01-29 18:33:04 +01:00
José Valim 47ef3d0abc Add missing parens to elixir.bat 2019-01-29 17:21:22 +01:00
José Valim e08a2b2642 More fixes on Windows with werl 2019-01-29 15:40:17 +01:00
José Valim 50cab0b962 Add RELEASE_NODE, RELEASE_COOKIE and fixes 2019-01-29 15:30:51 +01:00
José Valim dc030376d6 Basic mix release support (#8677)
See #8612.
2019-01-28 21:42:07 +01:00
José Valim 427c2aa3ec Revamp Elixir CLI (#8595)
This commit adds 6 new options to elixir CLI to aid releases:

  * `--pipe-to PIPEDIR LOGDIR` - invokes run_erl with daemon pipe and logs (only on Unix-like systems)

  * `--rpc-eval NODE COMMAND` - evaluates the given expression on the given node

  * `--boot FILE`, `--boot-var VAR VALUE`, `--erl-config FILE` and `--vm-args FILE` - which are equivalent to Erlang's `-boot`, `-boot_var`, `-config` and `-args_file`

We have also rewritten the CLI to only pass Elixir options to Kernel.CLI.
2019-01-08 20:44:43 +01:00
José Valim a14e2eb316 Suggest quotes where appropriate (#8561) 2019-01-02 14:40:22 +01:00
José Valim f045475934 Remove undocumented environment variable 2018-12-23 19:00:41 +01:00
Eksperimental dc7a35c3a0 Rephrase useWerl option in elixir.bat (#8559) 2018-12-22 09:06:05 +01:00
Eksperimental 3a3d68385e Revise use of "flag" terminology (#8347) 2018-11-16 09:53:53 +01:00
José Valim 8f0fe3d23f Remove unecessery releases directory check (#7359)
This check was added when Elixir itself was used as a release
but that's not the case anymore.
2018-02-17 09:08:00 +01:00
robi-wan 9386542fba Support path with spaces as argument to elixir.bat (#6596)
Erlang parameters (CLI switch '--erl') are used with possible quotes around the argument removed ('%~1').
This causes an error if one arbitrary argument to elixir.bat represents a quoted path with spaces in it:
"[part of path after space] was unexpected at this time."

Enclose the complete expression with quotes to work around this (the quotes are not added to the content).

This behavior is not documented in the [Windows XP Command Line Reference for SET](https://www.microsoft.com/resources/documentation/windows/xp/all/proddocs/en-us/set.mspx)
but there are other places which document the [SET command](https://ss64.com/nt/set.html).

Fix for #6455
2017-09-24 12:07:19 +02:00
robi-wan fd486d0d9d Do not start oldshell alongside IEx, closes #5730 (on Windows) (#6168) 2017-05-30 09:26:45 +02:00
José Valim 82b655a1a0 Do not start oldshell alongside IEx, closes #5730
Prior to this patch, both oldshell and IEx would start,
which would make them compete for the standard io. This
could be deterministically triggered by pasting input
with multiple lines on the terminal.

This commit guarantees the oldshell is no longer started.
2017-05-29 11:29:27 +02:00
Aleksei Magusev be25f60abc Correct indentation in elixirc output 2017-04-23 13:46:11 +02:00
Andrea Leopardi ec088749db Use single-equals when comparing variables in bin/elixir (#6028)
Double-equals is a Bash-specific alias for "=" and it doesn't work
everywhere. We use single-equal in the rest of the script anyways.
2017-04-22 15:15:49 +02:00
Eksperimental 33c5f50d5e Improvements to elixirc command (#5977) 2017-04-16 12:19:28 +02:00
Eksperimental acc19f8e39 Document --help option in elixir command and include long version of --version (#5971) 2017-04-10 11:29:05 +01:00
Eksperimental 5b0a3d5b2c Standardize elixirc bin files (#5970)
* Use present continuous in elixirc bin files
* Align descriptions of options in elixirc bin files
* Leave 30 chars to the left
* Options start with 2 white-spaces
2017-04-10 11:28:12 +01:00
Eksperimental 9f10e28b1a Standardize iex bin files (#5972)
* Align descriptions of options in iex bin files
* Options start with 2 white-spaces
* Document --help option in iex command and include long version of --version
2017-04-10 11:26:25 +01:00
José Valim 414a26627c Disable ansi detection for powershell to avoid false positives
Closes #5615

Signed-off-by: José Valim <jose.valim@plataformatec.com.br>
2017-01-05 10:49:39 +01:00
John Fearnside 535bf1532c Make batch style more consistent (#4944) 2016-07-05 21:00:51 +02:00
John Fearnside 52a14ccfb3 detect terminal, detect ANSI support (#4942) 2016-07-05 17:17:12 +02:00
eksperimental 3bd976737e Use proper case for proper nouns and acronyms
Use proper case for proper nouns (e.g., Elixir, Rebar, Git, and others)
as well as acronyms (e.g., URL, HTTP, and others).
2016-06-06 15:17:59 +02:00
robi-wan 501f856a23 Windows: batch file improvements (#4642)
* Add usage information to iex.bat

Support command line switch '--help', '-h', '/h' and '/?' to show usage information for iex.bat.
Check argument with '/I' to make the test case insensitive:
This allows showing usage information with '--HELP', '-H' and '/H'.

Use 'setlocal' and 'endlocal' so changes to the environment are local to the batch file
(https://technet.microsoft.com/en-us/library/bb491001.aspx) - so there is no need to un-set __ELIXIR_IEX_FLAGS.

* Use documented syntax 'goto label' - without leading colon before the label

* Support cli switch '/?' to show help

Use label :end to jump to the end of the batch file after showing help text -
so the call to elixir.bat is not executed when showing help.

Use 'setlocal' and 'endlocal' so that the env var 'argc' is local to this batch file.

* Support cli switch '/?' to show help for elixir.bat

Test for cli switch '/?' does not need to be case insensitive.
2016-05-18 22:22:41 +02:00
José Valim 38b784927f Improve elixirc options and use upcoming waiting mode 2016-05-15 09:23:34 +02:00
José Valim 66b97943b4 Update docs and CHANGELOG 2016-03-17 13:31:36 +01:00
Andrea Leopardi 4ea3d6499f Add --logger-otp and --logger-sasl to the command-line args
I added the following command-line arguments to the ./bin/elixir binary:

  * `--logger-otp true|false` - to configure the `:handle_otp_reports`
    of the `:logger` application
  * `--logger-sasl true|false` - to configure the `:handle_sasl_reports`
    of the `:logger` application
2016-03-17 11:04:33 +01:00
José Valim 214e2a3a7d Add in PATH note to remaining files 2016-02-18 07:40:52 +01:00
Jay Hayes 118e05e271 Improve documentation for iex -S 2016-02-17 16:34:30 -06:00
Brett N. DiFrischia 8310c9b9ac Use IEX_WITH_WERL environment variable to enable --werl by default. 2015-12-23 15:30:40 -06:00
Brett N. DiFrischia 1330de1eda Add environment variable to iex.bat so user can default to --werl if desired. 2015-12-22 11:16:40 -06:00
Franco Lombardo 6f80bf1bff mix.bat changed to emulate mix script on Unix-like systems. This solves #4075
Using mix file as input to elixir. Note that #!/usr/bin/env elixir will be
intepreted as an Elixir comment
2015-12-14 21:49:53 +01:00
Joe Yates c78755a0fb Documentation fixes 2015-12-03 23:28:20 +01:00
Onorio Catenacci 5ffb2c570d Adding code to the Windows batch files to make it easier to diagnose issues on Windows with Elixir 2015-12-01 12:24:54 -05:00
eksperimental 7b2fa9192a Use Title Case and backticks for Erlang and Elixir applications
It includes Erlang, Elixir, ExUnit, ExDoc, Logger, IEx, elixirc

It leaves Mix for a different PR.

Command to spot these words:

    ag -s '(?<!(\`))(?<!(\.))(?<!(/))(?<!(:))(?<!(_))(erlang|elixir|eex|iex|ex_unit|ex_doc|logger|elixirc)(?!(:))(?!(\?))(?!(_))(?!(-))(?!(\.))(?!(\`))(?!(/))(?!(>))' \
    --ignore "*.erl" --ignore "*.yrl" --ignore "*.src"
2015-09-09 01:51:22 +07:00
titib c604cba4db Update elixir.bat
Correct issue https://github.com/elixir-lang/elixir/issues/3619

Signed-off-by: José Valim <jose.valim@plataformatec.com.br>
2015-08-27 14:26:21 +02:00
Lars Storjord 72256bc094 Add support for --werl in Windows bash-like shells 2014-12-10 18:00:27 +01:00
José Valim 5eae31bd2c Do not set not shell as we know have a custom prompt 2014-10-15 12:28:13 +02:00
José Valim e099901fe3 Remove unecessary comment 2014-10-08 13:29:09 +02:00
Haoming Zhu 594c300a1b fix previous commit typo bug 2014-09-12 01:48:04 +08:00
Chris Hyndman 6bb4c4de03 Use quotes to avoid space-in-path issues with cygpath 2014-08-11 15:13:50 -07:00
José Valim a2662a4b51 Ensure elixir and iex works on MinGW 2014-08-10 15:11:18 +02:00
José Valim 1d29262949 Check for terminal on both stdout and stderr 2014-08-10 14:40:46 +02:00