2024-05-18 19:55:41 发布
网友
例如,我经常忘记在别人的电脑上注销你的网站,但并不总是有机会回去注销。如何使一个功能,将自动关闭所有会话,除了我的当前一个,从我的电脑
我认为有多种方式来看待这个问题。下面是我用的那个
使用TMOUT
将以下行添加到bash启动文件中,例如$HOME/.bash\u profile,或者在/etc/profile.d目录中创建一个名为timout-settings.sh的新bash shell脚本:
## append in $HOME/.bash_profile ## 300 seconds == 5 minutes ## TMOUT=300 readonly TMOUT export TMOUT
或/etc/profile.d/timout-settings.sh
#!/bin/bash ## 300 seconds == 5 minutes ## TMOUT=300 readonly TMOUT export TMOUT
我认为有多种方式来看待这个问题。下面是我用的那个
使用TMOUT
将以下行添加到bash启动文件中,例如$HOME/.bash\u profile,或者在/etc/profile.d目录中创建一个名为timout-settings.sh的新bash shell脚本:
或/etc/profile.d/timout-settings.sh
相关问题 更多 >
编程相关推荐