Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Replace Git Bash with conda #395

Closed
rgaiacs opened this issue Apr 4, 2017 · 18 comments
Closed

Replace Git Bash with conda #395

rgaiacs opened this issue Apr 4, 2017 · 18 comments

Comments

@rgaiacs
Copy link
Contributor

rgaiacs commented Apr 4, 2017

Michael Sarahan suggested to consider conda. Add your comments here.

@rgaiacs
Copy link
Contributor Author

rgaiacs commented Apr 4, 2017

conda doesn't has nano, see ContinuumIO/anaconda-issues#1485. The main point of consider replace Git Bash is to avoid issues related with nano at Windows and free us to maintain the compilation of anything that will provide nano for Windows users.

@msarahan
Copy link

msarahan commented Apr 4, 2017

conda does have nano, I created a package specifically for software carpentry: https://anaconda.org/swc/nano

There's only windows packages right now, but I could do linux/mac builds if anyone wanted.

We've had this discussion before, but the main advantage that conda offers (IMHO) is that you can create purpose-built installers for every platform on a per-workshop basis, using Constructor: https://github.com/conda/constructor

Note that Conda, Constructor, and Conda-build are all BSD projects, and in no way corporate-controlled by Continuum. They are supported and maintained by Continuum, but available for forking should that ever be necessary.

@ashander
Copy link

ashander commented Apr 4, 2017

We've had this discussion before, but the main advantage that conda offers (IMHO) is that you can create purpose-built installers for every platform on a per-workshop basis, using Constructor: https://github.com/conda/constructor

Is this referencing the mailing list discussion found here http://lists.software-carpentry.org/pipermail/discuss/2015-October/thread.html#3452 or something else?

@msarahan
Copy link

msarahan commented Apr 4, 2017

Yes, @ashander that's mostly what I had in mind. I am not sure that Constructor was available at that time, though. Since you can create installers specific for a given workshop, it can greatly reduce the steps to get people set up.

@evanwill
Copy link
Contributor

evanwill commented Apr 4, 2017

This seems like a great option for workshops that include Python.

So Conda installs python, bash, git, and nano? Does it provide a terminal emulator so that people don't have to use Windows cmd? Is there a way to get the terminal to work in Jupyter notebook on Windows?

Is there an example installer or instructions available some where?

thanks.

@msarahan
Copy link

msarahan commented Apr 4, 2017

Conda should be good at this point for workshops teaching either Python or R. We have rstudio packages in conda. We don't have much R experience internally, but we work hard to support the R ecosystem.

With constructor, people would only need to run the installer. It's based on conda, but does not actually require conda as part of the installer (only requires it if you want to have your installed thing be upgradeable later.)

I'm not sure about terminal emulators. I think you mean something like Console2? We don't currently have conda packages for that, but it should be easy to add. For the terminal in the notebook, that's also something that seems achievable: jupyter/notebook#172 but I don't know exactly how much work it would take.

@mingwandroid
Copy link

mingwandroid commented Apr 4, 2017

Anaconda Distribution has m2-mintty if that's any use? It doesn't have some of the fancy features Console2 has (which MSYS2 doesn't have since it cannot be compiled with GCC on Windows) but it does support the POSIX emulation layer a lot better (since it's maintained for Cygwin, more or less).

@biologyguy
Copy link

Hi folks,
I'm merging in from related issue #353. I'll be running a workshop in May and have completely switched the instructions so all installation is managed via Conda.
https://biologyguy.github.io/2017-05-08-NIH/
If anyone is game, I'd really value a review of my instructions. I'll also report back any issues our students encounter.

@msarahan
Copy link

@biologyguy cool, nice to see. Here's a few comments:

  1. Your process will be simpler if you build custom installers using Constructor (https://github.com/conda/constructor) - you can include everything you need, so that your install process will be just one step.
  2. The install instructions I used in Fall 2015 are at https://jiarong.github.io/2015-11-05-ND/ - maybe they're useful to you. Constructor didn't exist yet, or I would have used it.
  3. In your step3 for installing on Windows, I'd recommend that you tell people to not add PATH entries. Instead, miniconda creates a shortcut called "Anaconda Prompt" - it is cmd.exe, but drops you into your root environment being activated. Activation is much more reliable than setting PATH entries, because activation can possibly also set other environment variables. If you want the "anaconda prompt" shortcut in your own installer, include the "console_shortcut" conda package in your constructor list of packages.

Good luck, and ping me if you have questions.

@biologyguy
Copy link

Thanks @msarahan!
For constructor, if I'm reading it correctly, I would need to make and host a different installer for each platform? Or maybe I just make one for Windows, because the other systems have a more straight forward install? I think I'll try it with the list of shell commands for now and see if it messes anyone up.
Thanks for the tip about setting the PATH variable. I've added console_shortcut to the package list and a note to launch the Anaconda prompt from the start menu.

@msarahan
Copy link

@biologyguy yes, you would need to make and host separate installers for each platform. If you have a complicated set of things to install, maybe it's better than telling people the command to type. For simple stuff, maybe the juice is not worth the squeeze.

If anyone was bored, it would be really neat to create an on-demand installer generator. Instructors would only need to create and submit their constructor.yml files, then they'd get links to downloads out the other side. I'm pretty sure you could do this with free CI services, and then dump files somewhere free or cheap.

@ostueker
Copy link

ostueker commented Apr 27, 2017

I gave it a try and created a Conda (Constructor) based installer and I will use it for a spring course in a few weeks.

The code is at: https://github.com/ostueker/SWC-Conda-Installer.

It still needs a bit of cleanup and an EULA. Feedback on missing modules is welcome as well.

@msarahan
Copy link

Looks great @ostueker - thanks for your work on it.

@tmorrell
Copy link
Contributor

I'd like to add a vote for a conda-based install process. 'conda install -c swc nano' was a really easy way to get around nano install problems on windows at a recent workshop. A more automated solution would be even better.

@ostueker
Copy link

ostueker commented May 4, 2017

I've just created a v0.0.5 release for the SWC-Conda-Installer and uploaded installers for Linux, MacOSX and Windows.

Please feel free to test and give some feedback.

@msarahan
Copy link

msarahan commented May 4, 2017

@ostueker you should prefer the m2-git package over the git package for windows. The former is msys2 (and older), while the latter is a repackaged Git 4 Windows. Git 4 Windows is using a not-quite-compatible core of MSYS2, so mixing the two is not a good idea. It would be easy to create the equivalent of the "Git Bash" start menu shortcut that employed MSYS2's utilities.

If anyone here is interested in having permission to upload packages to the swc anaconda.org channel, let me know.

@ostueker
Copy link

ostueker commented May 4, 2017

Thanks @msarahan !
I'm also not quite happy that the Windows Start Menu folder is called "Anaconda3 (64bit)" as this can collide with already installed Anaconda installations.
The next weeks I'll be very busy, but I'll try to look at it later in the summer (so far I've never packaged something for conda).

@fmichonneau
Copy link
Contributor

closing as stale

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

9 participants