Pharo Install - A tool for installing Pharo Smalltalk packages.
PI is a MIT-pip-like command line application installer for Pharo Smalltalk. Copy & pasting install scripts is an easy method, but it’s also time consuming because of the manual interaction.
PI turns copy & paste Smalltalk (Metacello Configurations) install scripts into bash one-liners which works on Unix/Linux, MacOS and Windows (MinGW/MSYS). PI automatically tries to download necessary dependencies for parsing both SmalltalkHub and GitHub repositories lists, and also downloads the latest stable Pharo image and virtual machine if none is found in the current directory. It also supports installing multiple packages at once.
curl -O https://raw.githubusercontent.com/hernanmd/pi/master/pi
wget --no-cache --no-check-certificate https://raw.githubusercontent.com/hernanmd/pi/master/pi
Copy the executable script to a location included in the PATH environment variable:
chmod 755 pi mv pi /usr/local/bin
- Listing packages supports GitHub and SmalltalkHub repositories.
- Installing packages is supported for:
- Metacello Configurations from Catalog (command line handler: get)
- SmalltalkHub (command line handler: config)
- It works with curl or wget.
- Supports case-insensitive searching for package names or developer user name.
- The "image" option defaults to the current Pharo "stable" version.
- Assume only one image in a directory. Future version will add support for multiple images.
- PI can query SmalltalkHub or GitHub.
- PI can install packages from SmalltalkHub (GitHub repositories is currently working progress).
- Package search is case-sensitive.
- For GitHub repositories:
- If it has "pharo" as topic, it will be listed.
- If jq (a command line JSON processor) is not available, it will be downloaded to the directory where pi was executed.
- For SmalltalkHub repositories:
- If xmllint is not available, it will be downloaded to the directory where pi was executed.
Search both in SmalltalkHub and GitHub repositories:
If you experiment problems with pi, check first the versions of the following dependencies (copy & paste results when submitting an issue). PI is being developed in the following environment:
$ bash --version GNU bash, version 4.4.19(1)-release (x86_64-pc-msys) Copyright (C) 2016 Free Software Foundation, Inc.
$ git --version git version 2.16.2.windows.1
$ wget --version GNU Wget 1.19.4 built on mingw32. -cares +digest +gpgme +https +ipv6 +iri +large-file +metalink -nls +ntlm +opie -psl +ssl/openssl
$ openssl version OpenSSL 1.0.2n 7 Dec 2017
Working on your first Pull Request? You can learn how from this free series How to Contribute to an Open Source Project on GitHub
If you have discovered a bug or have a feature suggestion, feel free to create an issue on Github.
If you'd like to make some changes yourself, see the following:
- Fork this repository to your own GitHub account and then clone it to your local device
- Edit the pi file with your favorite text editor.
- Test PI.
- Add to add yourself as author below.
- Finally, submit a pull request with your changes!
- This project follows the all-contributors specification. Contributions of any kind are welcome!
- Remove the caching "feature" for Pharo GihHub packages.
- For obtaining the count of GitHub packages download just one item which is enough.
- Set download application once.
- Make download applications silent.
- Remove temprary JSON files from GitHub
- Added help usage details
- List Pharo GitHub package names.
- Download GitHub package list paginating results (still needs fix & testing)
- Minor enhacements
- Removed unnecessary function checkLibXML()
- Removed --no-check-certificate for the Pharo zeroconf website
- Added specific platform function for installing libXML
- Added function installLibXMLMSYS to install 32-bit and 64-bit versions depending on platform architecture
- All variable names now are lowercased
- Started to implement function to install packages from GitHub
- Timestamp output ?
- Implement GitHub package installation
- Install individual packages instead of only Metacello Configurations.
- Uninstall packages
This software is licensed under the MIT License.
Copyright Hernán Morales, 2018.
Permission is hereby granted, free of charge, to any person obtaining a copy of this software and associated documentation files (the "Software"), to deal in the Software without restriction, including without limitation the rights to use, copy, modify, merge, publish, distribute, sublicense, and/or sell copies of the Software, and to permit persons to whom the Software is furnished to do so, subject to the following conditions:
The above copyright notice and this permission notice shall be included in all copies or substantial portions of the Software.
THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.