Files and Folders

How to delete a folder which is nested quite deep and to avoid “File name too long”?
Timothy Duff, Uncategorized

To delete the directory tree starting at c:\subdir\more\offending_dir:

The total step-by-step-process is as simple as this:

cd c:\subdir\more to cd into its parent directory.
mkdir empty to create an empty directory.
robocopy empty offending_dir /mir to mirror the empty directory into the offending one.
After some waiting you’re done! Finish it up with:
rmdir offending_dir to get rid of the now empty offending directory and
rmdir empty to get rid of your intermediate empty directory.


How To Edit Your Hosts File
APPC Support, Uncategorized

Windows

Step 1 – Search for Notepad, then right-click on Notepad in the search results list, and choose Run as administrator. If you’re using Windows 10, a shortcut to Notepad is in the Start Menu.

Step 2 – Once NotePad is open, Go to File -> Open… and copy/paste the following file path:
c:\windows\system32\drivers\etc\hosts
Click open to start editing the hosts file.

Step 3 – Make your desired additions or alterations. Most likely you’ll be pasting something at the bottom of the document.

Tip: Adding a hashtag to the start of a line will disable it. For example, the line
# 128.91.58.195 origin.factcheck.org
won’t have any effect, but it will retain the host assignment for later use.

Step 4 – Go to File -> Save to commit the change that we just made.


macOS

Step 1 – Go to and Open Terminal either by searching for it or by locating it under the Applications folder

Step 2 – Once Terminal is open, copy/paste or type the following command:
sudo nano /etc/hosts
and press enter to execute the command. You’ll be prompted to enter your password to proceed.

Tip: Not seeing anything when you type your password? Don’t panic! That’s intentional. When entering your password through terminal the text is invisible for security purposes.

Step 3 – Make your desired additions or alterations. Most likely you’ll be pasting something at the bottom of the document.

Tip: Adding a hashtag to the start of a line will disable it. For example, the line
# 128.91.58.195 origin.factcheck.org
won’t have any effect, but it will retain the host assignment for later use.

Step 4 – Press ^X (hold the control key and press the X key) to save and exit. You’ll see a prompt at the bottom of the text editor asking you to confirm your changes (press the Y key) as well as the file to save to (just press Enter). You can now safely quit Terminal.


How To Map a Network Drive (PC)
Timothy Duff, Uncategorized

1. Click on the Windows Explorer icon in the start bar.

2. Right click the “Computer” tab, click “Map network drive”.

3. In the resulting pop-up window, select a drive letter (in this case, Y:), and enter the full network address (i.e. example.appc.upenn.edu). Be sure to check the “Reconnect at sign-in” checkbox. Then click Finish.

The folder should be mapped automatically, but if it’s not, use your login credentials for authentication.


How To Map a Network Drive (OSX)
Zachary Reese, Uncategorized

In Finder, select Go > Connect to Server (⌘+K). In the field labeled Server Address, type the IP address or local name of the drive you’d like to connect to.

 

Click Connect. You may see a prompt for credentials. Select Registered User and enter your username and password.

 

Click Connect again.

To make the mapping persistent (meaning you don’t have to do it every time you restart), go to System Preferences > Users & Groups.

OSX Login Items

Select your account from the sidebar list, then choose the Login Items tab.

OSX Login Items

Click the + icon below the list of login items, then use Finder to navigate to the network drive.

Finder Mount Volume

Click Add. Find the network drive in the list of login items and toggle the checkbox to active to enable mounting at login.