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

  • Home
  • SEARCH
  • 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 7781091
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: June 1, 20262026-06-01T19:06:56+00:00 2026-06-01T19:06:56+00:00

I have followed instructions from How can I run Cygwin Bash Shell from within

  • 0

I have followed instructions from How can I run Cygwin Bash Shell from within Emacs? this question and I have gone further and added the (setq explicit-bash-args '("--login" "-i")) command, however emacs continues to only display the dos prompt when I type M-x shell. In summery my .emacs file looks like this:

(defun cygwin-shell ()
  "Run cygwin bash in shell mode."
  (interactive)
  (let ((explicit-shell-file-name "C:/cygwin/bin/bash"))
    (call-interactively 'shell)))
(setq explicit-bash-args '("--login" "-i"))`

Please be gentle with the answers as I am right at the bottom of the famous vertical emacs learning curve!

  • 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-06-01T19:06:58+00:00Added an answer on June 1, 2026 at 7:06 pm

    If you implemented the answer from that question, note that you have to do M-x cygwin-shell to start bash. If you want to use it for every M-x shell you need to call

    (setq explicit-shell-file-name "C:/cygwin/bin/bash")
    

    Since you stated that you are learning, here’s a few tips when trying this out.

    • type C-x C-f ~/.emacs to open your .emacs file in your user path.
    • Enter your function above at the end
    • M-x load-file [RET] .emacs: loads the buffer (no need to restart emacs)
    • C-h a: If you are interested in some specific action, you can look it up
    • C-h v [RET] variable: can inspect the variable, check the value of explicit-bash-args for instance

    And, btw, I’m not sure what the “–login -i” does, but someone stated in a comment that you should have that so “ls” would work. If you have your cygwin bin path in your PATH environment variable, bash will find ls anyway. No need to escape the path variable either, this is handled by bash (do an echo $PATH in bash when you get it working and you’ll see).

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

Sidebar

Related Questions

I have followed the Accepted Answer's instructions from this post as regards creating a
I have followed the instructions on this page to get started on ActionMailer. After
See update below. This is driving me mad. I have followed all the instructions
I need to find a sound library for haskell. I have followed instructions of
I have followed the instructions found at http://code.google.com/p/pubsubhubbub/wiki/DeveloperGettingStartedGuide to setup a hub. When I
I have followed these instructions exactly, yet I get a Page cannot be found
I have followed the instructions here: http://help.github.com/win-set-up-git/ to set up git on my windows
I have followed the instructions on http://railscasts.com/episodes/147-sortable-lists for creating a sortable list. The list
I have followed the following instructions in setting a git repository locally in one
Here's my situation. I have followed the exact instructions on wordpress codex page about

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.