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
Add tphp command #233
base: develop
Are you sure you want to change the base?
Add tphp command #233
Conversation
bin/tphp
Outdated
script_path="$( cd "$(dirname "$0")" ; pwd -P )" | ||
|
||
if [[ -z "$1" ]]; then | ||
$script_path/tbash php |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
A lot of people are using tzsh instead of tbash. Can you think of a way to make this configurable?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
That's a good point! How about a variable in .env?
I've called it INTERACTIVE_SHELL
since SHELL is an existing standard environment variable (and we only use the variable where we want an interactive shell, otherwise we use bash), but open to better naming suggestions. It defaults to bash.
We could potentially also add a tshell
command that runs either bash or zsh depending on your configuration, but I haven't done it here. Might be useful to use in the docs.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
looks good :)
I've been using it locally for a while and discovered some issues with handling of args recently, will just convert it to a draft until I fix those |
This PR adds a tphp command for executing commands inside the php container.
Example:
This makes it a bit more convenient to use the install/cron/purge/etc aliases without needing to tbash in to the container.