GithubHelp home page GithubHelp logo

matischrodinger / get-winget Goto Github PK

View Code? Open in Web Editor NEW

This project forked from axlfc/get-winget

0.0 0.0 0.0 150 KB

Windows shell & powershell scripts to install last version of winget, unattended program installations and customize terminal

Home Page: https://axlfc.github.io/#GetWinget

PowerShell 100.00%

get-winget's Introduction

get-winget

Windows shell & powershell script to install version v1.0.11692 of winget, Window's default package manager, directly from the Windows shell itself.

Install procedure:

Install App Installer from Microsoft Store. You may need to run the cmd or Powershell: with administrative privileges. MINGW and MSYS2 might be run as administrator also.

  • Knowing actual Windows Execution Policy:

Get-ExecutionPolicy

  • To get all the execution directives that affect the current session and display them in order of precedence:

Get-ExecutionPolicy -List

  • To see the actual scope of the Execution Policy for the current user using the windows machine:

Get-ExecutionPolicy -Scope CurrentUser

  • Enable Execution of scripts (be careful to know your previous Policy of execution and to launch shell with administrator privileges, consider changing it back to the same Execution Policy as the previous one after installing winget via this script to prevent possible malware vulnerabilities associated with the Execution Policy. You should be knowing what are you doing... )

Set-ExecutionPolicy RemoteSigned

  • Navigate to the same folder via cmd or powershell (example):

cd c:\Users\USERNAME\Documents\Scripts\get-winget

  • Download the script, check for recent stable versions of releases of winget github inside the script variable to hold the url of winget's intaller from its github.

  • Execute install-winget script to begin the installation of winget on the computer if the Execution Policies have been correctly set.

Invoke-WebRequest https://github.com/Axlfc/get-winget/blob/main/install-winget.ps1 -OutFile install-winget.ps1

.\install-winget.ps1

  • Reconsider changing back to the previous Execution Policy you had before the changes made (if there are any) in the previous steps. (optional but recommended)

Set-ExecutionPolicy Default

  • Remove get-winget folder and .ps1 script and winget-installer.msixbundle file.



  • Now you should be able to install applications via command using winget, Windows' package manager.

Examples:

winget --version

winget show

Running this in cmd/powershell will install MINGW, MSYS2, the app you desire and it's in the list shown previously in your Windows computer.

winget install git

winget install MSYS2



To clone this repository into your desired folder (You can use MINGW or MSYS2 with git installed to do this. Beware spaces in folder/file names...) optional

Inside MINGW or MINGW from MYSYS2 bash console you can:

cd ~/Documents/Scripts

git clone https://github.com/Axlfc/get-winget

TODO: get winget add_to_terminal_profile

get-winget's People

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.