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 6248529
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: May 24, 20262026-05-24T13:04:33+00:00 2026-05-24T13:04:33+00:00

I am developing on a windows machine. The only place I need for linux

  • 0

I am developing on a windows machine. The only place I need for linux command line is Git Bash. The problem is: When I open it, I am in the home directory. I have to change the directory to my workspace, like:

cd ../../../d/work_space_for_my_company/project/code_source

Can I wrap this in a .sh file so I don’t have to hand-type it anymore? This should be simple but I have zero knowledge about Linux command line. I am really appreciated If you can walk me
through how to create that .sh file.

  • 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-24T13:04:34+00:00Added an answer on May 24, 2026 at 1:04 pm

    Just write that line to a file “cd.sh”, then do this from your shell prompt:

    . ./cd.sh
    

    Or you can create an alias or function in your $HOME/.bashrc file:

    foo() { cd /d/work_space_for_my_company/project/code_source ; }
    

    If the directory name includes spaces or other shell metacharacters, you’ll need quotation marks; it won’t hurt to add them even if they’re not necessary:

    foo() { cd "/d/Work Space/project/code_source" ; }
    

    (Note that I’ve omitted the ../../..; you don’t need it.)

    EDIT: If you add a line

    foo
    

    to your .bashrc after the function definition, your shell will start in that directory. Or you can just use the cd command directly in your .bashrc if you aren’t going to need to use the function later.

    (The name foo is just an example; you should pick a more meaningful name.)

    • 0
    • Reply
    • Share
      Share
      • Share on Facebook
      • Share on Twitter
      • Share on LinkedIn
      • Share on WhatsApp
      • Report

Sidebar

Related Questions

I am developing an application from windows vista machine. The web application is hosted
I am developing a simple ASP.Net application on a Windows 7 x64 machine using
I am developing a Windows .NET application (WinForms) and I need to simulate a
While developing ASP.net applications on a Windows 7 machine in Visual Studio. Sometimes I
I am developing using a Windows 7 machine with the local server being UniServer.
I'm developing an OpenGL application for Windows XP. The target machine has 2 NVIDIA
I'm developing a gae application on a windows machine. to have session handling I
I was developing Windows Mobile applications on a Windows machine using C#, just to
I was currently developing Android applications on a windows machine and signing with a
I am developing in windows environment and my production server has linux. My goal

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.