Skip to content

Commit

Permalink
Merge pull request #173 from britive/feature/v2.0.0
Browse files Browse the repository at this point in the history
release/v2.0.0
  • Loading branch information
theborch authored Sep 20, 2024
2 parents 0f95035 + 8bb8b31 commit 56e03d4
Show file tree
Hide file tree
Showing 98 changed files with 724 additions and 900 deletions.
9 changes: 5 additions & 4 deletions .gitignore
Original file line number Diff line number Diff line change
Expand Up @@ -3,14 +3,15 @@ __pycache__/
*.py[cod]
*$py.class

*.sublime-*
.DS_Store
.idea*
.in
.out
.idea*
testing-variables.txt
.DS_Store
site/
lock-test.py
site/
test.py
testing-variables.txt

# IDE
.vscode/
Expand Down
32 changes: 29 additions & 3 deletions CHANGELOG.md
Original file line number Diff line number Diff line change
@@ -1,7 +1,33 @@
# Change Log
# Changelog

* As of v1.4.0 release candidates will be published in an effort to get new features out faster while still allowing
time for full QA testing before moving the release candidate to a full release.
> As of v1.4.0, release candidates will be published in an effort to get new features out faster while still allowing
> time for full QA testing before moving the release candidate to a full release.
## v2.0.0 [2024-09-09]

__What's New:__

* Added colors to banner output.
* Added Step Up authentication to `my_secrets`

__Enhancements:__

* Switched to `ruff` for style linting and code-quality checking.

__Bug Fixes:__

* Fixed issue with global `default_tenant` test.

__Dependencies:__

* Dropped `python3.7` support.
* Dropped `pkg_resources` dependency.
* Upgrade `britive` to `>=3.0.0`
* Upgrade `click` to `>=8.1.7`

__Other:__

* Dropped legacy `import` functionality for the now long deprecated Node.js CLI.

## v1.8.3 [2024-08-20]

Expand Down
3 changes: 1 addition & 2 deletions CONTRIBUTING.md
Original file line number Diff line number Diff line change
Expand Up @@ -40,8 +40,7 @@ Environment variables that should be set for testing include the following.

* `PYBRITIVE_HOME_DIR` - a path to a home directory where `.britive` directory will be created
* `PYBRITIVE_TEST_TENANT` - the tenant name to be used for testing purposes
* `PYBRITIVE_NPM_IMPORT_PROFILE_ALIAS_VALUE` - the IDs of a profile that can be used to test the import process. This
should be in format `"appid/envid/profileid/appname"`
* `PYBRITIVE_TEST_PROFILE` - the profile to be used for testing purposes
* `PYBRITIVE_ENCRYPTED_CREDENTIAL_PASSPHRASE` - the password for encrypted file credential storage
* `PYBRITIVE_PREPARE_DOT_BRITIVE` - set to true if you want to have the `.britive` directory cleared before starting the
tests
Expand Down
7 changes: 3 additions & 4 deletions docs/index.md
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,7 @@ PyBritive is intended to be used as a CLI application for communicating with the

## Requirements

* Python 3.7 or higher
* Python 3.8 or higher
* Active Britive tenant (or nothing is really going to work)

## Installation
Expand Down Expand Up @@ -118,10 +118,9 @@ set REQUESTS_CA_BUNDLE="C:\Users\User\AppData\Local\corp-proxy\cacert.pem"
Before `pybritive` can connect to a Britive tenant, it needs to know some details about that tenant.
This is where `pybritive configure` will help us.

There are 2 ways to tell `pybritive` about tenants.
There is an easy way to tell `pybritive` about tenants.

1. `pybritive configure import`: this will import an existing configuration from the Node.js version of the Britive CLI.
2. `pybritive configure tenant`: This will prompt (or optionally the values can be passed via flags) for tenant details.
* `pybritive configure tenant`: This will prompt (or optionally the values can be passed via flags) for tenant details.

An alias for a tenant can be created in case more than 1 tenant is configured for use. This may be the case for admins
who may have access to an EA and GA tenant.
Expand Down
50 changes: 38 additions & 12 deletions pyproject.toml
Original file line number Diff line number Diff line change
Expand Up @@ -11,23 +11,31 @@ authors = [{name = "Britive Inc.", email = "[email protected]"}]
description = "A pure Python CLI for Britive"
readme = "README.md"
classifiers = [
"Programming Language :: Python :: 3",
"License :: OSI Approved :: MIT License",
"Operating System :: OS Independent"
"Operating System :: OS Independent",
"Programming Language :: Python",
"Programming Language :: Python :: 3.8",
"Programming Language :: Python :: 3.9",
"Programming Language :: Python :: 3.10",
"Programming Language :: Python :: 3.11",
"Programming Language :: Python :: 3.12",
"Topic :: Internet",
"Topic :: Security",
"Topic :: Utilities",
]
license = {file = "LICENSE"}
requires-python = ">= 3.7"
requires-python = ">= 3.8"
dependencies = [
"britive>=2.25.0",
"click",
"cryptography>=41.0.0",
"britive>=3.0.0",
"click>=8.1.7",
"colored",
"cryptography",
"jmespath",
"merge-args",
"pyjwt",
"python-dateutil",
"PyYAML",
"requests>=2.31.0",
"setuptools; python_version >= '3.12'",
"tabulate",
"toml"
]
Expand Down Expand Up @@ -63,10 +71,28 @@ where = ["src"]
plugins.md013.line_length = 120
plugins.md013.code_block_line_length = 120

[tool.black]
[tool.ruff]
include = ["pyproject.toml", "src/**/*.py", "tests/*.py"]
line-length = 120
skip-string-normalization = true

[tool.pylint]
max-line-length = 120
disable = "C0114,C0116,E0401"
[tool.ruff.format]
quote-style = "single"
indent-style = "space"
skip-magic-trailing-comma = false
line-ending = "auto"

[tool.ruff.lint]
select = [
"E", # pycodestyle
"F", # Pyflakes
"I", # isort
"PL", #pylint
"SIM", # flake8-simplify
]

[tool.ruff.lint.pylint]
allow-magic-value-types = ["int", "str"]
max-args = 16
max-branches = 30
max-returns = 8
max-statements = 72
6 changes: 3 additions & 3 deletions requirements.txt
Original file line number Diff line number Diff line change
@@ -1,9 +1,10 @@
beautifulsoup4
boto3
britive>=2.25.0
britive>=3.0.0
certifi
charset-normalizer
click~=8.1.7
click>=8.1.7
colored
cryptography
google-cloud-compute
jmespath
Expand All @@ -15,7 +16,6 @@ pytest
python-dateutil
PyYAML
requests
setuptools; python_version >= "3.12"
tabulate
toml
twine
Expand Down
2 changes: 1 addition & 1 deletion src/pybritive/__init__.py
Original file line number Diff line number Diff line change
@@ -1 +1 @@
__version__ = '1.8.3'
__version__ = '2.0.0'
Loading

0 comments on commit 56e03d4

Please sign in to comment.