Sign Up

Sign Up to our social questions and Answers Engine to ask questions, answer people’s questions, and connect with other people.

Have an account? Sign In

Have an account? Sign In Now

Sign In

Login to our social questions & Answers Engine to ask questions answer people’s questions & connect with other people.

Sign Up Here

Forgot Password?

Don't have account, Sign Up Here

Forgot Password

Lost your password? Please enter your email address. You will receive a link and will create a new password via email.

Have an account? Sign In Now

You must login to ask a question.

Forgot Password?

Need An Account, Sign Up Here

Please briefly explain why you feel this question should be reported.

Please briefly explain why you feel this answer should be reported.

Please briefly explain why you feel this user should be reported.

Sign InSign Up

The Archive Base

The Archive Base Logo The Archive Base Logo

The Archive Base Navigation

  • SEARCH
  • Home
  • About Us
  • Blog
  • Contact Us
Search
Ask A Question

Mobile menu

Close
Ask a Question
  • Home
  • Add group
  • Groups page
  • Feed
  • User Profile
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Buy Points
  • Users
  • Help
  • Buy Theme
  • SEARCH
Home/ Questions/Q 3227162
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: May 17, 20262026-05-17T16:32:32+00:00 2026-05-17T16:32:32+00:00

Tried to set some aliases in my .bashrc file. This one… export alias umusic=/Volumes/180

  • 0

Tried to set some aliases in my .bashrc file. This one…

export alias umusic="/Volumes/180 gram/Uncompressed/"

…gets the following error…

-bash: cd: /Volumes/180: No such file or directory

…when I try “cd $umusic”.

I’ve tried various methods of escaping that whitespace in the directory name, to no avail. (180\ gram, 180%20gram, single quotes, double quotes, no quotes.) I realize the easiest solution is to rename the directory to “180gram,” but I’d like to know how to solve this particular problem.

I’m on a Mac, if that makes any difference.

  • 1 1 Answer
  • 0 Views
  • 0 Followers
  • 0
Share
  • Facebook
  • Report

Leave an answer
Cancel reply

You must login to add an answer.

Forgot Password?

Need An Account, Sign Up Here

1 Answer

  • Voted
  • Oldest
  • Recent
  • Random
  1. Editorial Team
    Editorial Team
    2026-05-17T16:32:32+00:00Added an answer on May 17, 2026 at 4:32 pm

    Your use of the export command is making umusic an environment variable and not an alias. The export command exports environment variables named on the rest of the command line, optionally with new values. So it’s exporting an environment variable named alias (which probably isn’t set) and one named umusic.

    Given that you’re expanding an environment variable, the shell does the following substitution:

    cd $umusic
    cd /Volumes/180 gram/Uncompressed/
    

    which generates the error you get because the space isn’t quoted. If instead you do:

    cd "$umusic"
    

    then the expansion is

    cd "/Volumes/180 gram/Uncompressed/"
    

    which is what you’re expecting.

    However, using an environment variable for this might be still a bit too much work, since you have to quote the expansion. Instead, try this alias:

    alias umusic="cd '/Volumes/180 gram/Uncompressed'"
    

    which you would run with just

    $ umusic
    $ pwd
    /Volumes/180 gram/Uncompressed
    
    • 0
    • Reply
    • Share
      Share
      • Share on Facebook
      • Share on Twitter
      • Share on LinkedIn
      • Share on WhatsApp
      • Report

Sidebar

Related Questions

I want to achieve this using html and css: I have tried to set
I'm trying to set some custom defaults for the jQuery validation plugin. I've tried
How can I set some of the tabs in a JTabbedPane invisible? I tried
I am using Qt 4.6.3, and tried to set some placeholder text on a
I'm trying to set up some Network stuff. For this reason I need to
I am trying to set some session information in one web method and return
I have this simple Bean class and try to set some values with BeanUtils.setProperty
I tried to set the tick style to tsManual, the min and max position
I tried to set the background color of a data grid view to be
I tried to set the usergent using Inet1.Execute , GET, Referer: yahoo.com & vbCrLf

Explore

  • Home
  • Add group
  • Groups page
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Users
  • Help
  • SEARCH

Footer

© 2021 The Archive Base. All Rights Reserved
With Love by The Archive Base

Insert/edit link

Enter the destination URL

Or link to existing content

    No search term specified. Showing recent items. Search or use up and down arrow keys to select an item.