@弟妹,
Bash 总是至少读取完整的一行
读取
alias lll='ls -ll';lll
接着立即扩展别名
alias
不是别名,lll
也不是别名(你的alias lll='ls-ll'
此时还未执行),所以不用扩展最后再执行命令
- 执行
alias lll='ls -ll'
- 执行
lll
@无名啊,抱歉 我不是用我举得例子测试的。我现在明白了,不加引号,是参数没有携带。并且会提示alias 没有ll参数
现在明白你引用的大意了,所以我补充了我的需求场景,明白alias不符合我的要求了
@弟妹,看来你是没看懂大意,也没看英文原文呐。。
并不行哦
ubuntu@ubuntu:~$ alias lll='ls-ll';lll
Command 'lll' not found, did you mean:
command 'llc' from deb llvm
command 'dll' from deb brickos
command 'llt' from deb storebackup
command 'lli' from deb llvm-runtime
Try: sudo apt install <deb name>
Bash 手册里,Alias 条目说:
Bash always reads at least one complete line of input, and all lines that make up a compound command, before executing any of the commands on that line or the compound command. Aliases are expanded when a command is read, not when it is executed. Therefore, an alias definition appearing on the same line as another command does not take effect until the next line of input is read. The commands following the alias definition on that line are not affected by the new alias.
大意:
Bash 总是至少读取完整的一行(或多行,保证复合命令也读完整咯),接着立即扩展别名,最后再执行命令
另外,你的
ls -ll
需要用引号括起来,否则-ll
不是lll
的一部分,而是成为alias
的参数。如:$ alias lll='ls -ll'
红米K30 Pro(变焦版)
@老虎会游泳,我可以使用 虎绿林 API,为 小萌 GIF 开发“检查更新”的功能吗?
我的想法是:
- 当用户主动使用 小萌 GIF 时,应用自动在后台通过 虎绿林 API 访问本帖,查看帖子内容是否有新版。
- 如果有新版,引导用户通过浏览器打开本帖,下载新版。
- 每日最多自动访问 虎绿林 API 检查更新一次。
- 不会对虎绿林附件下载链接进行盗链。
@花花世界,我更新了第 8 版,可以截取视频片段了。
@TabKey9,改进了对于 Android 9.0 及以下版本的适配,现在转换 GIF 时可以直接保存,不用再多点一下了。
另外第 8 版增加和改进了许多功能,推荐更新。
@水木易安,我想分一个1/4的区域,拿来打1080p的游戏,用obs感觉延迟太高,玩不了
127.9.147.96
@罐子,
一加8Pro
@罐子,
一加8Pro
4k就好好的用200%啊
小米MIX2s(白)
现在已经不需要调整了。不知道为什么。配置不变
n2n、wireguard。
是不是端口被占用,还有没开启端口,或者防火墙
@值班电工,环境挺好,就是权限有毛病
用过一段时间,生态太糟糕了。
红米K30S
端口被占用,服务端或客户端
frp服务端白名单放行
服务端防火墙
服务器安全组或者系统防火墙瞧一瞧
红米K30 Pro(变焦版)