That would need to be a shell function (or the like).
Otherwise, when the `mkdir` process finishes, any chdir it did would have
had no effect on the parent process (e.g., your shell).
Something like this:

# create a directory and chdir into it
function mkcd { mkdir -pv "$@" && eval cd \"\$$#\"; }

On Wed, Aug 2, 2023 at 9:01 AM Tom LUCAS <cont...@tom-lucas.fr> wrote:

> Hello,
> I wish that we can add a flag to access directly at the newly created
> folder.
> This feature will allow to not type each time "mkdir mynewfolder && cd
> mynewfolder" or any other method with two lines
> Something like "mkdir -a mynewfolder" for access can be an idea
> Have a good day
>
> Tom
>
>
>
>
>
>
>

Reply via email to