Code Monkey home page Code Monkey logo

Comments (9)

schwern avatar schwern commented on August 24, 2024

cpanminus has been suggested.

Kane also points out that cpanp already does zero-conf. I'm skeptical.

from perl5i.

notbenh avatar notbenh commented on August 24, 2024

cpanm seems like a sane fit here, or are there other issues that should be addressed?

from perl5i.

schwern avatar schwern commented on August 24, 2024

cpanm mostly solves the problem. It certainly saves us from having to write our own.

What's missing from stock cpanm is you still have to configure it to install into your home directory and Perl to look there. As an example of the problem, look at the Quickstart Guide For Unix which shows how to solve that once and for all with perlbrew and cpam.

perlbrew might be overkill. Perhaps all we need is a utility to spit out the necessary environment variables, a la local::lib, which can be appended to your .bash_profile.

Ideally, I'd like to be able to let a user install perl5i in three commands and using their system perl.

  1. Download and install cpanm
  2. Download and append environment variables to ~/.bash_profile
  3. Install perl5i.

This could be...

# http://cpanmin.us/local would be a special cpanm installer that installs to ~/bin
# It doesn't exist.
curl -L http://cpanmin.us/local | perl - App::cpanminus

# Append the `export PERLBLAH` stuff from local::lib to your .bash_profile.
# This also doesn't exist.
curl -L http://cpanmin.us/local.bashrc > ~/.bash_profile

# Install perl5i
cpanm perl5i

These don't have to be cpanmin.us URLs, they could be perl5i github pages URLs to start. Point is its three commands that can be cut & pasted into just about any Unix shell.

from perl5i.

notbenh avatar notbenh commented on August 24, 2024

Why not just toss that script up as is and then we can just:

curl -L http://SCRIPTURL | bash -

Then it's just one command for the user to copy/paste

from perl5i.

schwern avatar schwern commented on August 24, 2024

I'm not comfortable with altering the user's permanent settings automatically. And they could be using .profile. They could be using a different shell.

They also need to make the environment changes in their current shell as well, or restart it.

from perl5i.

notbenh avatar notbenh commented on August 24, 2024

Fair objections to the all in one and done solution. Though seems that the way that perlbrew handles this is just say something like: all done now copy these lines in to your start up thinggie. Thus leaving that last step up to the user and when it breaks it's there problem. Also the script is open for all to see if some one wants to follow most of the steps but put things in other locations (for example).

Not a real solution on my part, I guess more banter from the me.

from perl5i.

schwern avatar schwern commented on August 24, 2024

On the one hand, it would be great if we could automate this. OTOH shell configurations are complicated things.

First pass, reduce our quickstart by removing perlbrew from the equation. perlbrew is great, but it takes a long time and doesn't help if you want to use a specific instance of perl.

Second pass, get it down to the three steps I mentioned.

Third pass, write something which will try to figure out which shell you're using and what file to append to. Offer to do it automatically, but leave it as a prompt. I wouldn't be surprised if local::lib already has most of this.

from perl5i.

notbenh avatar notbenh commented on August 24, 2024

+1

from perl5i.

schwern avatar schwern commented on August 24, 2024

I've cut down the installation process to just altering .bashrc to do the local::lib thing and installing perl5i. It's something you can cut and paste into the shell. I'm calling it good enough to close this up.
https://github.com/schwern/perl5i/wiki/Quickstart-Guide-For-Unix

from perl5i.

Related Issues (20)

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.