例如 hostname = "test.test.test",然后删除后结果应该像 "testtesttest"
最佳答案
$ foo=test.test.test
$ echo "${foo//./}"
testtesttest
关于linux - 如何删除 shell 脚本中字符串中所有出现的点?,我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/4332392/
例如 hostname = "test.test.test",然后删除后结果应该像 "testtesttest"
最佳答案
$ foo=test.test.test
$ echo "${foo//./}"
testtesttest
关于linux - 如何删除 shell 脚本中字符串中所有出现的点?,我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/4332392/
相关文章:
c - 适用于 Windows 的 MALLOC_TRACE
apache - 如何编写包装器 - 避免子 shell - 用于 apache2 重写映射或 shell 脚本的脚本?
linux - 使用 XenServer 内的 CentOS 5 无法解析主机名但 IP 地址的问题
c++ - 如何在 Linux 上通过 C++ 串行接口(interface)与 Arduino 通信?
php - ini_set ('post_max_size'、 '200M')在 php 5.4 中不起作用
mysql - 在 EC2 (ubuntu) 上设置 Mysql。 XFS 有问题