Giter Site home page Giter Site logo

rdmaclachlan / wingetintune Goto Github PK

View Code? Open in Web Editor NEW

This project forked from svrooij/wingetintune

0.0 0.0 0.0 6.01 MB

Upload any app from Winget to Intune

Home Page: https://www.nuget.org/packages/SvRooij.Winget-Intune.Cli/

License: GNU General Public License v3.0

Smalltalk 2.68% C# 96.13% PowerShell 1.19%

wingetintune's Introduction

Winget Intune packager CLI

GitHub issues Github sponsors

Take any (just msi installers for now) app from winget and upload it to Intune in minutes.

  • Downloading the installer and the logo
  • Creating an intunewin file automatically
  • Generating the needed script information
  • Publish the app to Intune.

This application is Windows only and requires Dotnet 7 to be installed on your computer. It's also a beta application, so please report any issues you find. A lot of commands run the winget command, so make sure you have the App Installer installed on your computer as well.

LinkedIn Profile Link Mastodon Follow on Twitter Check my blog

Installing

This package can be downloaded as a dotnet tool. Make sure you have Dotnet 7 installed on your computer. I'm working to get a code signing certificate, but for now you might have to configure an exception on your computer to run unsigned code.

# Install dotnet 7 sdk
winget install --id Microsoft.DotNet.SDK.7 --source winget

# Add the nuget feed, if that is not already done
dotnet nuget add source https://api.nuget.org/v3/index.json --name nuget.org

# This command will install the tool
dotnet tool install --global Svrooij.Winget-Intune.Cli

# or to update to the latest version
dotnet tool update --global SvRooij.Winget-Intune.Cli

Beta application

This is a beta application, it's not yet ready for production use. I'm still working on it, and I'm looking for feedback. If you found a bug please create an issue, if you have questions or want to share your feedback, check out the discussions page.

Commands

The CLI has several commands, try them out yourself.

Description:
  Enhanced Winget CLI for automations

Usage:
  winget-intune [command] [options]

Options:
  --version       Show version information
  -?, -h, --help  Show help and usage information

Commands:
  install <packageId>  Installs or upgrades a package
  check <packageId>    Check if a specific version in installed
  info <packageId>     Show package info as json
  package <packageId>  Package an app for Intune
  publish <packageId>  Publish an packaged app to Intune
  msi <msiFile>        Extract info from MSI file
  about                Information about this package and it's author

Package

You should definitely try the package command. as it's the most important one. Package an app from winget as an intunewin file, ready for uploading to intune. You can also expect a detection.ps1 file, that you should configure to be used as detection script in Intune, provided it's not a MSI installer, in that case you can find the detection information in the readme. It will also write a app.json file with all the information about the app, for automation purposes.

winget-intune package {PackageId} [--version {version}] [--source winget] --package-folder {PackageFolder}

The packageId is case sensitive, so make sure you use the correct casing. Tip: Copy it from the result of the winget search {name} command.

This command will download the content-prep-tool automatically, and use it to create the intunewin file. In a future version this might be replaced with a custom implementation, but for now this works.

Publish

The publish command will upload the intunewin file to Intune. You'll need to run the package command first. Not all packages will work for publishing, you can always try to manually upload the intunewin file to Intune.

# This app uses the built-in windows authentication, this will trigger a login prompt (or do sso).
winget-intune publish {PackageId} --package-folder {PackageFolder} --tenant {TenantId} --username {Username}

# You can also provide a token, this is useful for automation.
winget-intune publish {PackageId} --package-folder {PackageFolder} --token {Token}

Library (soon)

I'm planning to release the actual intune specific code as a separate library, so you can use it in your own projects. This will be released as a separate package.

Contributing

If you want to contribute to this project, please check out the contributing page and the Code of Conduct.

wingetintune's People

Contributors

svrooij avatar

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.