Most Popular

1500 questions
147
votes
11 answers

How can I embed programming source code in Powerpoint slide and keep code highlighting?

Is it possible to embed programming source code to Powerpoint slide, and keep code highlighting/coloring?
Yousui
  • 1,827
147
votes
8 answers

Find Items in one column that are not in another column

I have two columns in Excel, and I want to find (preferably highlight) the items that are in column B but not in column A. What's the quickest way to do this?
C. Ross
  • 6,344
147
votes
1 answer

How do I delete all files smaller than a certain size in all subfolders?

I have a folder with many sub-folders containing small tif files (less than 160kb) which have been merged together in bigger pdf files, together with some big multi-page tif files. I want to delete all small tif files without deleting the bigger…
To Do
  • 2,490
147
votes
14 answers

Why arrow keys are not recommended in Vim

"Never use arrow keys in Vim!" I heard this from a random speaker, but didn't have the chance to ask him why. Also, if you don't use the arrow keys, how can you move the cursor in the Insert mode?
Mike Lee
  • 649
147
votes
4 answers

Display each sub-directory size in a list format using one line command in Bash?

I want to get a list of the directories and their sizes in a list format like how you get when you do a ls -l. The thing is that is there a one line command that can do this? I see others have long commands just to output this. That's just too…
147
votes
9 answers

How do I make Bash my default shell on Ubuntu?

I have a .bash_profile in my home directory, but it isn't getting run on login. If I do the following, then things seem to be as I expect: ssh myhost bash source ~/.bash_profile But normally that all happens on login. Thoughts?
147
votes
14 answers

Google Chrome automatically adding websites to my list of search engines?

I have noticed that certain websites (e.g. Stack Exchange sites, Dell, etc.) are automatically added to my list of search engines in Google Chrome. They even add a keyboard shortcut to their entry. Here are some examples: Dell: Keyboard ->…
147
votes
6 answers

What is Windows' equivalent of the "which" command in Unix? Is there an equivalent PowerShell command?

In Linux, we have the "which" command to find out the path of an executable. What is its Windows equivalent? Is there any PowerShell command for doing that?
Invincible
147
votes
11 answers

When ssh'ing, how can I set an environment variable on the server that changes from session to session?

When I ssh into a server, how can I pass an environment variable from the client to the server? This environment variable changes between different invocations of ssh so I don't want to overwrite $HOME/.ssh2/environment every time I do an ssh call.…
Ross Rogers
  • 4,517
147
votes
15 answers

Manually closing a port from commandline

I want to close an open port which is in listening mode between my client and server application. Is there any manual command line option in Linux to close a port? NOTE: I came to know that "only the application which owns the connected socket…
codingfreak
147
votes
4 answers

What are the holes on the sides of a computer case frame for?

Many computer cases have these holes / cut-outs on the frame. What are they for?
VAN
  • 1,539
146
votes
6 answers

How to prevent SSH from disconnecting if it's been idle for a while

I have a ssh connection to a machine which gets disconnected by that machine after 30 minutes of no user input. However, if I start something like top, the connection stays alive. Since this is a client's machine, I can not reconfigure that…
Isaac
  • 1,874
146
votes
12 answers

How to check if I have sudo access?

I recently got into trouble because of this. $sudo vim /etc/motd [sudo] password for bruce: bruce is not in the sudoers file. This incident will be reported. Is there a way to check if I have sudo access or not?
Bruce
  • 3,137
146
votes
14 answers

Remove file without asking

How can I remove a file without asking the user if he agrees to delete the file? I am writing shell script and use rm function, but it asks "remove regular file?" and I really don't need this.
hey
  • 2,176
  • 5
  • 22
  • 24
146
votes
6 answers

How do I reverse selected lines order in Vim?

For example, if I have four lines as follows: the first line the second line the third line the fourth line I want to reverse them to the fourth line the third line the second line the first line How could I do this in Vim?
Jichao
  • 7,470