[Date Prev][Date Next] [Thread Prev][Thread Next] [Date Index] [Thread Index]

Re: alias in bash script issue





On Sat, Mar 4, 2023 at 5:53 PM David <bouncingcats@gmail.com> wrote:
On Sat, 4 Mar 2023 at 19:30, Ken Young <ken@highwinds.cloud> wrote:

> Do you know why my alias can't work in the bash script?
> The info is as follows.
>
> 1)  this alias does exist
> $ alias |grep 'k='
> alias k='minikube kubectl --'
>
> 2) it also exists in .bash_profile
> $ cat ~/.bash_profile |grep 'k='
> alias k="minikube kubectl --"

[...]

> ./get.sh: line 5: k: command not found

[...]

> Please give suggestions.

Hi. Friends don't help friends to do bad things :)

Debian's default shell is 'dash'. Its manual, readable using 'man dash',
says

   


Hi,

my debian 11's default shell is just bash.

root@nxacloud-bloghost:~# echo $SHELL

/bin/bash

root@nxacloud-bloghost:~# lsb_release -cd

Description: Debian GNU/Linux 11 (bullseye)

Codename: bullseye

Thanks 

Reply to: