Skip to content

Commit

Permalink
(chocolatey-community#45) Replace au references with chocolatey-au wh…
Browse files Browse the repository at this point in the history
…ere appropriate
  • Loading branch information
TheCakeIsNaOH committed Jan 12, 2024
1 parent fbde190 commit 6397ce4
Show file tree
Hide file tree
Showing 6 changed files with 28 additions and 33 deletions.
4 changes: 1 addition & 3 deletions .appveyor.yml
Original file line number Diff line number Diff line change
@@ -1,5 +1,3 @@
# AU template: https://github.com/majkinetor/au-packages-template

version: '{build}'
max_jobs: 1
image: WMF 5
Expand Down Expand Up @@ -54,7 +52,7 @@ install:
- ps: $PSVersionTable
- git --version
- ps: |
git clone -q https://github.com/majkinetor/au.git $Env:TEMP/au
git clone -q https://github.com//chocolatey-community/chocolatey-au.git $Env:TEMP/au
. "$Env:TEMP/au/scripts/Install-AU.ps1" $Env:au_version
- ps: |
Expand Down
8 changes: 2 additions & 6 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -15,22 +15,18 @@ This contains Chocolatey packages, both manually and automatically maintained.

### Folder Structure

* automatic - where automatic packaging and packages are kept. These are packages that are automatically maintained using [AU](https://chocolatey.org/packages/au).
* automatic - where automatic packaging and packages are kept. These are packages that are automatically maintained using [chocolatey-au](https://github.com/chocolatey-community/chocolatey-au).
* icons - Where you keep icon files for the packages. This is done to reduce issues when packages themselves move around.
* manual - where packages that are not automatic are kept.

For setting up your own automatic package repository, please see [Automatic Packaging](https://chocolatey.org/docs/automatic-packages)

### Requirements

* Chocolatey (choco.exe)

#### AU

* PowerShell v5+.
* The [AU module](https://chocolatey.org/packages/au).

For daily operations check out the AU packages [template README](https://github.com/majkinetor/au-packages-template/blob/master/README.md).
* The [chocolatey-au module](https://github.com/chocolatey-community/chocolatey-au).

### Getting started

Expand Down
10 changes: 5 additions & 5 deletions automatic/README.md
Original file line number Diff line number Diff line change
@@ -1,12 +1,12 @@
## Automatic Folder

This is where you put your Chocolatey packages that are automatically packaged up by [AU](https://chocolatey.org/packages/au).
This is where you put your Chocolatey packages that are automatically packaged up by [chocolatey-au](https://github.com/chocolatey-community/chocolatey-au).

Execute `update_all.ps1` in the repository root to run [AU](https://chocolatey.org/packages/au) updater with default options.
Execute `update_all.ps1` in the repository root to run [chocolatey-au](https://github.com/chocolatey-community/chocolatey-au) updater with default options.

To fully setup all the features ensure you perform the steps in the [setup/README.md](https://github.com/chocolatey/chocolatey-packages-template/blob/master/setup/README.md#automatic-updater-au)
To fully setup all the features ensure you perform the steps in the [setup/README.md](https://github.com/chocolatey/chocolatey-packages-template/blob/master/setup/README.md)

To get the packages that implement AU updater run `Get-AUPackages` or `lsau` in this directory.
To get the packages that implement chocolatey-au updater run `Get-AUPackages` or `lsau` in this directory.

**NOTE:** Ensure when you are creating packages for AU, you don't use `--auto` as the packaging files should be normal packages. AU doesn't need the tokens to do replacement.
**NOTE:** Ensure when you are creating packages for chocolatey-au, you don't use `--auto` as the packaging files should be normal packages. chocolatey-au doesn't need the tokens to do replacement.

12 changes: 6 additions & 6 deletions setup/README.md
Original file line number Diff line number Diff line change
@@ -1,9 +1,9 @@
# Setup Automatic Updater (AU)
# Setup Automatic Updater (chocolatey-au)

* Ensure you have the [Chocolatey PowerShell profile](https://chocolatey.org/docs/troubleshooting#why-does-choco-intab-not-work-for-me) installed.
* Ensure you have the [Chocolatey PowerShell profile](https://docs.chocolatey.org/en-us/troubleshooting#why-does-choco-tab-not-work-for-me) installed.
* Open `au_setup.ps1` in an editor and review it.
* Run PowerShell `5.x` as Administrator (AU framework supports PowerShell 6+ but this setup does not)
* Run PowerShell `5.x` as Administrator (chocolatey-au framework supports PowerShell 6+ but this setup does not).
* Run `au_setup.ps1`.
* Configure AU [plugins](https://github.com/majkinetor/au/blob/master/Plugins.md).
* Configure [AppVeyor](https://github.com/majkinetor/au/wiki/AppVeyor).
* Configure [local run](https://github.com/majkinetor/au/wiki#local-run).
* Configure chocolatey-au [plugins](https://github.com/chocolatey-community/chocolatey-au/blob/master/Plugins.md).
* Configure [AppVeyor](https://github.com/chocolatey-community/chocolatey-au/wiki/AppVeyor).
* Configure [local run](https://github.com/chocolatey-community/chocolatey-au/wiki#local-run).
25 changes: 14 additions & 11 deletions setup/au_setup.ps1
Original file line number Diff line number Diff line change
@@ -1,17 +1,20 @@
# WMF 3/4 only
# upgrade powershell
if ($PSVersionTable.PSVersion -lt $(New-Object System.Version("5.0.0.0"))) {
choco install dotnet4.5.1 -y
choco upgrade powershell-packagemanagement --ignore-dependencies -y
choco install powershell -y
}

$refreshenv = Get-Command refreshenv -ea SilentlyContinue
if ($refreshenv -ne $null -and $refreshenv.CommandType -ne 'Application') {
refreshenv # You need the Chocolatey profile installed for this to work properly (Choco v0.9.10.0+).
$UpdateSessionEnvironment = Get-Command Update-SessionEnvironment -ea SilentlyContinue
if ($UpdateSessionEnvironment -ne $null -and $UpdateSessionEnvironment.CommandType -ne 'Application') {
Update-SessionEnvironment # You need the Chocolatey profile installed for this to work properly (Choco v0.9.10.0+).
} else {
Write-Warning "We detected that you do not have the Chocolatey PowerShell profile installed, which is necessary for 'refreshenv' to work in PowerShell."
Write-Warning "We detected that you do not have the Chocolatey PowerShell profile installed, which is necessary for 'Update-SessionEnvironment' to work in PowerShell."
}

Install-PackageProvider -Name NuGet -Force
Set-PSRepository -Name PSGallery -InstallationPolicy Trusted
Install-Module au -Scope AllUsers
Get-Module au -ListAvailable | select Name, Version
# Switch to this once chocolatey-au is released
# choco install chocolatey-au -y

choco install git.portable -y
# Required as git is installed to Get-ToolsLocation and is added to the PATH
Update-SessionEnvironment
git clone -q https://github.com/chocolatey-community/chocolatey-au.git $Env:TEMP/chocolatey-au
. "$Env:TEMP/chocolatey-au/scripts/Install-AU.ps1" "master"
2 changes: 0 additions & 2 deletions update_all.ps1
Original file line number Diff line number Diff line change
@@ -1,5 +1,3 @@
# AU Packages Template: https://github.com/majkinetor/au-packages-template

param([string] $Name, [string] $ForcedPackages, [string] $Root = "$PSScriptRoot\automatic")

if (Test-Path $PSScriptRoot/update_vars.ps1) { . $PSScriptRoot/update_vars.ps1 }
Expand Down

0 comments on commit 6397ce4

Please sign in to comment.