Git Product home page Git Product logo

suptejas / electric Goto Github PK

View Code? Open in Web Editor NEW
239.0 13.0 12.0 138.95 MB

A fast, futuristic package manager for Windows.

Home Page: https://electric.sh

License: Apache License 2.0

Python 73.56% Batchfile 1.27% Inno Setup 0.73% PowerShell 0.18% HTML 0.20% Rust 15.21% Makefile 8.60% TypeScript 0.20% CSS 0.06%
package-manager python cli automation it-admin electric windows alpha powershell powertool devops server package-management powertools software-management

electric's Introduction

Electric

A futuristic, powerful and fast package manager for Windows.


Installing 7-Zip Through Electric

Highly optimized for speed and usability, Electric is anywhere from 200% to 1500% faster than other market competitors for downloading Applications and Packages, and has incredible speeds for concurrent / parallel downloading.

Electric believes in incredible efficiency, and is the only Windows package manager that officially supports installing packages concurrently.

Built for today's systems and with good support for lower specced systems, Electric runs smoothly even on systems with as little as 2 GB of ram!

Note: Since electric is in an alpha phase, it might not be completely stable yet. Feel free to open any issues or bug reports at issues.

โšก Installation

First you'll need to set your execution policy to RemoteSigned if not done so:

Set-ExecutionPolicy RemoteSigned

Method 1: Install Using Official Installer

Download the latest version of the electric Installer from the Releases Page

After completing the download, run the installer and follow the simple installation prompts.

Open your Command Prompt (cmd.exe) or alternatively Powershell (powershell.exe) and type electric to get a list of help commands.

Method 2: Install Using Powershell

Run the following command on your powershell window:

iwr -useb get.electric.sh | iex

Method 3: Build From Source

Prerequisites: Git, Python 3.x

  1. Clone the github repository using the Github CLI.
git clone https://www.github.com/electric-package-manager/electric
  1. Change to the electric directory.
cd electric
  1. Install it locally using the Python package manager (pip)
pip install --editable .
  1. Register Tab Completion

  2. Type electric to get a help menu of commands.


๐Ÿงช Testing

First, make sure you Build From Source.

Run this command to run the tests for electric

python -m unittest discover src/tests

๐Ÿ‘ Supporters

Stargazers repo roster for @electric-package-manager/electric

Forkers repo roster for @electric-package-manager/electric


๐Ÿ”จ Build Status

Feature Build Status
Installation โœ…
Portable Installation โœ…
Uninstallation โœ…
Update โœ…
Show โœ…
List โœ…
Search โœ…
Code Editor Extension Installation โœ…
Python Package Installation โœ…
NodeJS Package Installation โœ…
Configuration Management โœ…
Cleanup โœ…
Tab Completion โœ…

Tab Completion

When using the official Electric installer, tab completion is setup for you out of the box, however, it is possible to manually add tab completion for electric. Add the below lines to your powershell profile:

Register-ArgumentCompleter -Native -CommandName electric -ScriptBlock {
    param($wordToComplete, $commandAst, $cursorPosition)
    [Console]::InputEncoding = [Console]::OutputEncoding = $OutputEncoding = [System.Text.Utf8Encoding]::new()
    $Local:word = $wordToComplete.Replace('"', '""')
    $Local:ast = $commandAst.ToString().Replace('"', '""')
    electric complete --word="$Local:word" --commandline "$Local:ast" --position $cursorPosition | ForEach-Object {
        [System.Management.Automation.CompletionResult]::new($_, $_, 'ParameterValue', $_)
    }
}

Then, restart your powershell and you've setup tab completion!

Authors

Tejas - Founder And Developer Of Electric

See also the list of contributors who participated in this project.

Special thanks to: @ZaphodElevated who built the terminal animation you saw above.

Built With

Python 3

Click

Versioning

We use SemVer for versioning. For the versions available, see the tags on this repository.

License

This project is licensed under the Apache 2.0 License - see the LICENSE.md file for details.

electric's People

Contributors

amethyst69 avatar cursefroge avatar erick-dsnk avatar marikishtar007 avatar samrxth avatar suptejas avatar

Stargazers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

Watchers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

electric's Issues

Linux & Mac version

Is your feature request related to a problem? Please describe.
I only use Linux.

Describe the solution you'd like
A linux & macos version.

button without a project logo

Is your feature request related to a problem? Please describe.
When accessing the page, there is a button different from the project icon.

Describe the solution you'd like
I was thinking of collaborating and noticed the button that had a different icon of the project and thought to contribute to this small detail to this project.

Describe alternatives you've considered
I initially thought of doing something like this:

Screenshot 1: before
image

Screenshot 2: after
image

Additional context
This can improve brand consistency by ui/ux.

failed to install git

PS D:> electric install git
SuperCached [ Git ]
Installing Git
An Error Occured While Installing Git

Would You Like To See The Error Message? (Y/n): y
[WinError 216] This version of %1 is not compatible with the version of Windows you're running. Check your computer's system information and then contact the software publisher

These automatically generated links may help:
[1] <=> swcarpentry/windows-installer#49
[2] <=> AmazingAmpharos/OoT-Randomizer#112
[3] <=> https://appuals.com/how-to-fix-this-version-of-this-file-is-not-compatible-with-the-version-of-windows-youre-running-error-on-windows/
[4] <=> https://stackoverflow.com/questions/39635044/errorcreateprocess-error-216-this-version-of-1
[5] <=> https://stackoverflow.com/questions/54254331/error-216-this-version-of-1-is-not-compatible-with-the-version-of-windows-you
[6] <=> https://stackoverflow.com/questions/29565779/cannot-find-command-git-windows
[7] <=> https://stackoverflow.com/questions/70460348/unable-to-install-behave
[8] <=> https://stackoverflow.com/questions/13790592/how-to-upgrade-git-on-windows-to-the-latest-version
[9] <=> https://forum.qt.io/topic/117314/error-createprocess-error-216-this-version-of-1-is-not-compatible-with-the-version-of-windows-you-re-running
[10] <=> https://windowsreport.com/version-not-compatible-with-windows/
[11] <=> https://open62541.org/doc/current/building.html
[12] <=> https://answers.microsoft.com/en-us/windows/forum/all/this-verison-of-this-file-is-not-compatible-with/0c6a4c8e-1416-47a5-b6b4-6d10a82942da
[13] <=> https://www.atlassian.com/git/tutorials/install-git
[14] <=> https://www.youtube.com/watch?v=Qh2B8x7xL2s
[15] <=> https://intellij-support.jetbrains.com/hc/en-us/community/posts/360000094879-runnerw-exe-CreateProcess-failed-with-error-216-with-a-simple-Hello-World

[0000] => Installation failed due to an unknown reason.

We recommend you raise a support ticket with the data generated below:

{
Name => Git
Version => 3.0.2
Logfile => <--attachment-->
}

PowerShell install error

Describe the bug
The PowerShell install command fails with an error

To Reproduce
Run the following command on your powershell window:
iwr -useb get.electric.sh | iex

Output

404 Not Found
Not Found
The requested URL was not found on the server. If you entered the URL manually please check your spelling and try
again.
At line:1 char:1
+ iwr -useb get.electric.sh | iex
+ ~~~~~~~~~~~~~~~~~~~~~~~~~
    + CategoryInfo          : InvalidOperation: (System.Net.HttpWebRequest:HttpWebRequest) [Invoke-WebRequest], WebExc
   eption
    + FullyQualifiedErrorId : WebCmdletWebResponseException,Microsoft.PowerShell.Commands.InvokeWebRequestCommand

Expected behavior
Execution of an install script, I suppose.

utf-8 issue in Python.

Describe the bug
utf-8 issue on almost every command

PS C:\Users\Moi> electric install firefox
SuperCached [ Mozilla Firefox ]
โ–ˆโ–ˆโ–ˆโ–ˆโ–ˆโ–ˆโ–ˆโ–ˆโ–ˆโ–ˆโ–ˆโ–ˆโ–ˆโ–ˆโ–ˆโ–ˆโ–ˆโ–ˆโ–ˆโ–ˆโ–ˆโ–ˆโ–ˆโ–ˆโ–ˆโ–ˆโ–ˆโ–ˆโ–ˆโ–ˆ  56.6 / 56.6 MB
Verified Installer Hash
Installing Mozilla Firefox
Traceback (most recent call last):
  File "electric.py", line 2386, in <module>
  File "click\core.py", line 829, in __call__
  File "click\core.py", line 782, in main
  File "click\core.py", line 1259, in invoke
  File "click\core.py", line 1066, in invoke
  File "click\core.py", line 610, in invoke
  File "click\decorators.py", line 21, in new_func
  File "electric.py", line 467, in install
  File "utils.py", line 1553, in get_pid
UnicodeDecodeError: 'utf-8' codec can't decode byte 0x82 in position 57: invalid start byte
[2736] Failed to execute script electric
PS C:\Users\Moi>

To Reproduce
Any command triggers the bug.

Expected behavior
No error.

Desktop (please complete the following information):

  • OS: windows 10
  • Version 1.0.0

Multiple package installations in a single call

Is your feature request related to a problem? Please describe.
As of 1.0-stable, it does not seem possible to request installation for several packages at the same time. For example electric install nodejs python neovim git will throw the Got unexpected extra arguments error, instead of installing the 4 requested packages consecutively.

Describe the solution you'd like
Would be super handy of the installer could loop through all the requested packages, and execute an appropriate function based on availability

Describe alternatives you've considered
No alternatives available in Electric

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.