RimoChan / sese-engine

【sese-engine】新时代的搜索引擎!
https://sese.yyj.moe
Other
607 stars 53 forks source link

Ubuntu已安装tmux还是提示没有tmux #32

Closed jrz233 closed 1 year ago

jrz233 commented 1 year ago

IMG_20221114_140451_834

xiongnemo commented 1 year ago

IMG_20221114_140451_834

可以提供一下执行 which tmux 之后的返回值吗?($?

jrz233 commented 1 year ago

IMG_20221114_140451_834

可以提供一下执行which tmux之后的返回值吗?($?) 执行which tmux就是返回那个tmux地址啊

xiongnemo commented 1 year ago

IMG_20221114_140451_834

可以提供一下执行which tmux之后的返回值吗?($?) 执行which tmux就是返回那个tmux地址啊

我指的是这条命令的 exit status,你可以在执行 which 这条命令后再在 shell 中输入 $? 并回车来查看

jrz233 commented 1 year ago

IMG_20221114_140451_834

可以提供一下执行which tmux之后的返回值吗?($?) 执行which tmux就是返回那个tmux地址啊

我指的是这条命令的 exit status,你可以在执行 which 这条命令后再在 shell 中输入 $? 并回车来查看

IMG_20221115_123411 这样吗

xiongnemo commented 1 year ago

IMG_20221114_140451_834

可以提供一下执行which tmux之后的返回值吗?($?) 执行which tmux就是返回那个tmux地址啊

我指的是这条命令的 exit status,你可以在执行 which 这条命令后再在 shell 中输入 $? 并回车来查看

IMG_20221115_123411 这样吗

对的,为了方便复现可以再像如下所描述的提供一下 bash 的版本号吗?

从图中我大概了解了原因,但是还需要了解一下环境。

nemo@nemo-tablet-14c /tmp> bash --version
GNU bash, version 5.1.4(1)-release (x86_64-pc-linux-gnu)
Copyright (C) 2020 Free Software Foundation, Inc.
License GPLv3+: GNU GPL version 3 or later <http://gnu.org/licenses/gpl.html>

This is free software; you are free to change and redistribute it.
There is NO WARRANTY, to the extent permitted by law.
jrz233 commented 1 year ago

IMG_20221114_140451_834

可以提供一下执行which tmux之后的返回值吗?($?) 执行which tmux就是返回那个tmux地址啊

我指的是这条命令的 exit status,你可以在执行 which 这条命令后再在 shell 中输入 $? 并回车来查看

IMG_20221115_123411 这样吗

对的,为了方便复现可以再像如下所描述的提供一下 bash 的版本号吗?

从图中我大概了解了原因,但是还需要了解一下环境。

nemo@nemo-tablet-14c /tmp> bash --version
GNU bash, version 5.1.4(1)-release (x86_64-pc-linux-gnu)
Copyright (C) 2020 Free Software Foundation, Inc.
License GPLv3+: GNU GPL version 3 or later <http://gnu.org/licenses/gpl.html>

This is free software; you are free to change and redistribute it.
There is NO WARRANTY, to the extent permitted by law.

root@8d3d27d0ad2b:/# bash --version GNU bash,版本 5.0.17(1)-release (x86_64-pc-linux-gnu) Copyright (C) 2019 Free Software Foundation, Inc.

xiongnemo commented 1 year ago

IMG_20221114_140451_834

可以提供一下执行which tmux之后的返回值吗?($?) 执行which tmux就是返回那个tmux地址啊

我指的是这条命令的 exit status,你可以在执行 which 这条命令后再在 shell 中输入 $? 并回车来查看

IMG_20221115_123411 这样吗

对的,为了方便复现可以再像如下所描述的提供一下 bash 的版本号吗? 从图中我大概了解了原因,但是还需要了解一下环境。

nemo@nemo-tablet-14c /tmp> bash --version
GNU bash, version 5.1.4(1)-release (x86_64-pc-linux-gnu)
Copyright (C) 2020 Free Software Foundation, Inc.
License GPLv3+: GNU GPL version 3 or later <http://gnu.org/licenses/gpl.html>

This is free software; you are free to change and redistribute it.
There is NO WARRANTY, to the extent permitted by law.

root@8d3d27d0ad2b:/# bash --version GNU bash,版本 5.0.17(1)-release (x86_64-pc-linux-gnu) Copyright (C) 2019 Free Software Foundation, Inc.

if [[ $? -eq 0 ]] 改为 if [ -x tmux ] ,并删去 which tmux 那一行试试?

你的 bash 或是环境中缺少 [[,修改为 POSIX 兼容的写法应该能解决问题。

RimoChan commented 1 year ago

你们的 image 越来越多了!

jrz233 commented 1 year ago

IMG_20221114_140451_834

可以提供一下执行which tmux之后的返回值吗?($?) 执行which tmux就是返回那个tmux地址啊

我指的是这条命令的 exit status,你可以在执行 which 这条命令后再在 shell 中输入 $? 并回车来查看

IMG_20221115_123411 这样吗

对的,为了方便复现可以再像如下所描述的提供一下 bash 的版本号吗? 从图中我大概了解了原因,但是还需要了解一下环境。

nemo@nemo-tablet-14c /tmp> bash --version
GNU bash, version 5.1.4(1)-release (x86_64-pc-linux-gnu)
Copyright (C) 2020 Free Software Foundation, Inc.
License GPLv3+: GNU GPL version 3 or later <http://gnu.org/licenses/gpl.html>

This is free software; you are free to change and redistribute it.
There is NO WARRANTY, to the extent permitted by law.

root@8d3d27d0ad2b:/# bash --version GNU bash,版本 5.0.17(1)-release (x86_64-pc-linux-gnu) Copyright (C) 2019 Free Software Foundation, Inc.

if [[ $? -eq 0 ]] 改为 if [ -x tmux ] ,并删去 which tmux 那一行试试?

你的 bash 或是环境中缺少 [[,修改为 POSIX 兼容的写法应该能解决问题。

不行,还是提示找不到tmux,脚本如下 IMG_20221115_182142

xiongnemo commented 1 year ago

不行,还是提示找不到tmux,脚本如下 IMG_20221115_182142

要不直接把第一行的 shebang 改成 #!/bin/bash ?我自己机器上 sh bash 好像都可以的…… 或者直接 bash ./启动.sh 试试? 以及:如果可以的话能否贴个这个情况下的输出(报错)?

PS: 可以直接通过我个人主页中的邮箱联系到我

xiongnemo commented 1 year ago

结论:在给定条件(ubuntu:20.04)镜像中无法复现,此 issue 被搁置

屏幕截图 2022-11-15 205439 屏幕截图 2022-11-15 205420