Skip to content

Commit

Permalink
Merge pull request #42 from homebysix/1.8.1
Browse files Browse the repository at this point in the history
1.8.1 merge to master
  • Loading branch information
homebysix committed Dec 9, 2020
2 parents e62c388 + 2390d68 commit 64c543f
Show file tree
Hide file tree
Showing 6 changed files with 39 additions and 21 deletions.
5 changes: 2 additions & 3 deletions .pre-commit-config.yaml
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
repos:
- repo: https://github.com/pre-commit/pre-commit-hooks
rev: v2.4.0
rev: v3.3.0
hooks:
- id: check-ast
- id: check-byte-order-marker
Expand All @@ -16,7 +16,6 @@ repos:
- id: trailing-whitespace
args: [--markdown-linebreak-ext=md]
- repo: https://github.com/python/black
rev: 19.10b0
rev: 20.8b1
hooks:
- id: black
language_version: python3.7
10 changes: 9 additions & 1 deletion CHANGELOG.md
Original file line number Diff line number Diff line change
Expand Up @@ -3,6 +3,13 @@
All notable changes to this project will be documented in this file. This project adheres to [Semantic Versioning](http://semver.org/).


## [1.8.1] - 2020-12-08

### Removed
- Removed warning about setting MinimumVersion of AutoPkg recipes to 2.0+.
- Reverted 1.4 minimum version requirement for processors that use URLGetter (introduced in 1.7.0).


## [1.8.0] - 2020-10-08

### Changed
Expand Down Expand Up @@ -194,7 +201,8 @@ All notable changes to this project will be documented in this file. This projec
- Initial release


[Unreleased]: https://github.com/homebysix/pre-commit-macadmin/compare/v1.8.0...HEAD
[Unreleased]: https://github.com/homebysix/pre-commit-macadmin/compare/v1.8.1...HEAD
[1.8.1]: https://github.com/homebysix/pre-commit-macadmin/compare/v1.8.0...v1.8.1
[1.8.0]: https://github.com/homebysix/pre-commit-macadmin/compare/v1.7.0...v1.8.0
[1.7.0]: https://github.com/homebysix/pre-commit-macadmin/compare/v1.6.2...v1.7.0
[1.6.2]: https://github.com/homebysix/pre-commit-macadmin/compare/v1.6.1...v1.6.2
Expand Down
8 changes: 4 additions & 4 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -15,7 +15,7 @@ For any hook in this repo you wish to use, add the following to your pre-commit

```yaml
- repo: https://github.com/homebysix/pre-commit-macadmin
rev: v1.8.0
rev: v1.8.1
hooks:
- id: check-plists
# - id: ...
Expand Down Expand Up @@ -121,7 +121,7 @@ When combining arguments that take lists (for example: `--required-keys`, `--cat

```yaml
- repo: https://github.com/homebysix/pre-commit-macadmin
rev: v1.8.0
rev: v1.8.1
hooks:
- id: check-munki-pkgsinfo
args: ['--catalogs', 'testing', 'stable', '--']
Expand All @@ -131,7 +131,7 @@ But if you also use the `--categories` argument, you would move the trailing `--

```yaml
- repo: https://github.com/homebysix/pre-commit-macadmin
rev: v1.8.0
rev: v1.8.1
hooks:
- id: check-munki-pkgsinfo
args: ['--catalogs', 'testing', 'stable', '--categories', 'Design', 'Engineering', 'Web Browsers', '--']
Expand All @@ -143,7 +143,7 @@ If it looks better to your eye, feel free to use a multi-line list for long argu

```yaml
- repo: https://github.com/homebysix/pre-commit-macadmin
rev: v1.8.0
rev: v1.8.1
hooks:
- id: check-munki-pkgsinfo
args: [
Expand Down
11 changes: 11 additions & 0 deletions RELEASING.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,11 @@
# Releasing new versions of pre-commit-macadmin

1. Update the versions in __README.md__ and __pre_commit_hooks/\_\_init\_\_.py__.

1. Update the change log.

1. Merge development branch to master.

1. Create a GitHub release with version tag, prefixed with `v`. (For example: `v2.3.4`)

1. Run `pre-commit autoupdate` on a test repo and confirm it updates to the new version.
24 changes: 12 additions & 12 deletions pre_commit_hooks/check_autopkg_recipes.py
Original file line number Diff line number Diff line change
Expand Up @@ -152,12 +152,14 @@ def validate_minimumversion(process, min_vers, ignore_min_vers_before, filename)
"""Ensure MinimumVersion is set appropriately for the processors used."""

# Warn if using a MinimumVersion greater than or equal to 2
if LooseVersion(min_vers) >= LooseVersion("2"):
print(
"{}: WARNING: Choosing MinimumVersion {} limits the potential "
"audience for your AutoPkg recipe. Consider using MinimumVersion "
"1.4.1 if your processors support it.".format(filename, min_vers)
)
# warn_on_vers = "2"
# suggest_vers = "1.4.1"
# if LooseVersion(min_vers) >= LooseVersion(warn_on_vers):
# print(
# "{}: WARNING: Choosing MinimumVersion {} limits the potential "
# "audience for your AutoPkg recipe. Consider using MinimumVersion "
# "{} if your processors support it.".format(filename, min_vers, suggest_vers)
# )

# Processors for which a minimum version of AutoPkg is required.
# Note: Because LooseVersion considers version 1.0 to be "less than" 1.0.0,
Expand All @@ -167,8 +169,8 @@ def validate_minimumversion(process, min_vers, ignore_min_vers_before, filename)
"AppPkgCreator": "1.0",
"BrewCaskInfoProvider": "0.2.5",
"CodeSignatureVerifier": "0.3.1",
"CURLDownloader": "1.4",
"CURLTextSearcher": "1.4",
"CURLDownloader": "0.5.1",
"CURLTextSearcher": "0.5.1",
"DeprecationWarning": "1.1",
"EndOfCheckPhase": "0.1.0",
"FileFinder": "0.2.3",
Expand All @@ -194,9 +196,7 @@ def validate_minimumversion(process, min_vers, ignore_min_vers_before, filename)
"StopProcessingIf": "0.1.0",
"Symlinker": "0.1.0",
"Unarchiver": "0.1.0",
"URLDownloader": "1.4",
"URLGetter": "1.4",
"URLTextSearcher": "1.4",
"URLTextSearcher": "0.2.9",
"Versioner": "0.1.0",
}

Expand Down Expand Up @@ -238,7 +238,7 @@ def validate_no_superclass_procs(process, filename):
"""Warn if any superclass processors (which are used by other processors
rather than called in recipes) are used."""

# Processors that have been deprecated.
# Processors that are superclasses and shouldn't be referenced directly.
superclass_procs = ("URLGetter",)

passed = True
Expand Down
2 changes: 1 addition & 1 deletion setup.py
Original file line number Diff line number Diff line change
Expand Up @@ -7,7 +7,7 @@
name="pre-commit-macadmin",
description="Pre-commit hooks for Mac admins, client engineers, and IT consultants.",
url="https://github.com/homebysix/pre-commit-macadmin",
version="1.8.0",
version="1.8.1",
author="Elliot Jordan",
author_email="elliot@elliotjordan.com",
packages=["pre_commit_hooks"],
Expand Down

0 comments on commit 64c543f

Please sign in to comment.