Forums
New posts
Articles
Product Reviews
Policies
FAQ
Log in
Register
What's new
Search
Search
Search titles only
By:
New posts
Menu
Log in
Register
Install the app
Install
Forums
Apple Computing Products:
macOS - Apps and Programs
Terminal: Smart tab completion
JavaScript is disabled. For a better experience, please enable JavaScript in your browser before proceeding.
You are using an out of date browser. It may not display this or other websites correctly.
You should upgrade or use an
alternative browser
.
Reply to thread
Message
<blockquote data-quote="CaldwellYSR" data-source="post: 1346721" data-attributes="member: 200976"><p>As a recent switcher from Ubuntu (Well recent switch backer if that's a word) I'm finding myself in the command line a lot more than when I was a mac user before. One thing I really loved about Ubuntu was when I was compiling and running java programs for class my tab completion was really smart. When I needed to compile my class if I had a directory that looked like:</p><p>[CODE]</p><p>Example.java</p><p>Example.class</p><p>Client.java</p><p>Client.class[/CODE]</p><p></p><p>and I needed to compile the Client.java to take into account the most recent changes I would type:</p><p></p><p>[CODE]javac C [TAB][/CODE]</p><p></p><p>and it would complete to</p><p>[CODE]</p><p>javac Client.java[/CODE]</p><p></p><p>ignoring the .class files because you can't run javac on a .class. Also when I wanted to run the file typing</p><p></p><p>[CODE]java C [TAB][/CODE]</p><p></p><p>would result in</p><p></p><p>[CODE]java Client[/CODE]</p><p></p><p>with no period. This was a very smart way of doing the tab completion that I got so used to that now it's driving me crazy when I hit tab and it gives me the Client. without actually completing to what I need it to be.</p><p></p><p>So is there any way to make the Mac bash completion smarter so that it would have this same effect?</p></blockquote><p></p>
[QUOTE="CaldwellYSR, post: 1346721, member: 200976"] As a recent switcher from Ubuntu (Well recent switch backer if that's a word) I'm finding myself in the command line a lot more than when I was a mac user before. One thing I really loved about Ubuntu was when I was compiling and running java programs for class my tab completion was really smart. When I needed to compile my class if I had a directory that looked like: [CODE] Example.java Example.class Client.java Client.class[/CODE] and I needed to compile the Client.java to take into account the most recent changes I would type: [CODE]javac C [TAB][/CODE] and it would complete to [CODE] javac Client.java[/CODE] ignoring the .class files because you can't run javac on a .class. Also when I wanted to run the file typing [CODE]java C [TAB][/CODE] would result in [CODE]java Client[/CODE] with no period. This was a very smart way of doing the tab completion that I got so used to that now it's driving me crazy when I hit tab and it gives me the Client. without actually completing to what I need it to be. So is there any way to make the Mac bash completion smarter so that it would have this same effect? [/QUOTE]
Verification
Name this item 🌈
Post reply
Forums
Apple Computing Products:
macOS - Apps and Programs
Terminal: Smart tab completion
Top