Find centralized, trusted content and collaborate around the technologies you use most.
Teams
Q&A for work
Connect and share knowledge within a single location that is structured and easy to search.
次のコードで :t を理解しようとしていますが、理解できず、これらのコードは tcl で変換する必要があります。印刷すると、単語 the がスラッシュで分割され、最後の要素が返されます。例: user3、ユーザーなど
d = /home/etc/user/user3 とします。
while 1 { set _f $_d:t }
あなたはおそらく探しているfile tail:
file tail
set _f [file tail $_d]
通常、Tcl 変数名を で始めるのは適切なスタイルでは_ありませんが、必要に応じてそうすることは非常に合法です。
_