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

Fix bash error in usage example on README page #943

Merged
merged 2 commits into from
Feb 15, 2020

Conversation

abraj
Copy link
Contributor

@abraj abraj commented Jan 13, 2020

On Linux bash terminal, executing
echo "console.log('Hello, world!')"
gives the following error:
bash: !': event not found

To fix the issue, changing the log string from
Hello, world! to Hello, world

Tested on following systems:

  • Ubuntu 18.04.3 LTS
  • Linux Mint 19

On Linux bash terminal, executing
`echo "console.log('Hello, world!')"`
gives the following error:
`bash: !': event not found`

To fix the issue, changing the log string from
`Hello, world!` to `Hello, world`

Tested on following systems:
* Ubuntu 18.04.3 LTS
* Linux Mint 19
@coveralls
Copy link

coveralls commented Jan 13, 2020

Coverage Status

Coverage remained the same at 78.764% when pulling a15c795 on abraj:master into b90754e on TypeStrong:master.

@cspotcode
Copy link
Collaborator

@abraj Good catch, thanks. Can you think of any problems with switching the quotes around to keep the exclamation mark?

echo 'console.log("Hello, world!")' | ts-node

Switching the quotes around in the line
`echo "console.log('Hello, world!')" | ts-node`
to get the line as
`echo 'console.log("Hello, world!")' | ts-node`
in order to keep the exclamation mark, while also
avoiding the bash error at the same time.
@abraj
Copy link
Contributor Author

abraj commented Jan 13, 2020

@cspotcode Even better! I think that switching the quotes should be the way to go.
Works perfectly without any bash errors.

@cspotcode cspotcode merged commit 3eb46e0 into TypeStrong:master Feb 15, 2020
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants