Hidden features of Bash

insert preceding line’s final parameter alt–. the most useful key combination ever, try it and see, for some reason no one knows about this one. press it again and again to select older last parameters. great when you want to do something else to something you used just a moment ago.

Hidden Features of MySQL

Since you put up a bounty, I’ll share my hard won secrets… In general, all the SQLs I tuned today required using sub-queries. Having come from Oracle database world, things I took for granted weren’t working the same with MySQL. And my reading on MySQL tuning makes me conclude that MySQL is behind Oracle in … Read more

Hidden features of HTML

Using a protocol-independent absolute path: <img src=”//domain.example/img/logo.png”/> If the browser is viewing an page in SSL through HTTPS, then it’ll request that asset with the HTTPS protocol, otherwise it’ll request it with HTTP. This prevents that awful “This Page Contains Both Secure and Non-Secure Items” error message in IE, keeping all your asset requests within … Read more

Hidden features of Android development?

Hopefully there aren’t too many hidden, hidden features – but here’s some of the less well known and non-intuitive features available for Android that will definitely make your life easier and your apps better. All the source code for the platform and all the non-Google native apps is available for you to browse, download, borrow, … Read more

Hidden Features of VB.NET?

The Exception When clause is largely unknown. Consider this: Public Sub Login(host as string, user as String, password as string, _ Optional bRetry as Boolean = False) Try ssh.Connect(host, user, password) Catch ex as TimeoutException When Not bRetry ”//Try again, but only once. Login(host, user, password, True) Catch ex as TimeoutException ”//Log exception End Try … Read more

Hidden features of C

More of a trick of the GCC compiler, but you can give branch indication hints to the compiler (common in the Linux kernel) #define likely(x) __builtin_expect((x),1) #define unlikely(x) __builtin_expect((x),0) see: http://kerneltrap.org/node/4705 What I like about this is that it also adds some expressiveness to some functions. void foo(int arg) { if (unlikely(arg == 0)) { … Read more

tech