1password-secrets 0.0.1.dev260__tar.gz → 0.0.1.dev266__tar.gz

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (25) hide show
  1. {1password_secrets-0.0.1.dev260/1password_secrets.egg-info → 1password_secrets-0.0.1.dev266}/PKG-INFO +12 -22
  2. {1password_secrets-0.0.1.dev260 → 1password_secrets-0.0.1.dev266}/README.md +2 -3
  3. 1password_secrets-0.0.1.dev266/pyproject.toml +85 -0
  4. 1password_secrets-0.0.1.dev260/1password_secrets.egg-info/SOURCES.txt +0 -22
  5. 1password_secrets-0.0.1.dev260/1password_secrets.egg-info/dependency_links.txt +0 -1
  6. 1password_secrets-0.0.1.dev260/1password_secrets.egg-info/entry_points.txt +0 -2
  7. 1password_secrets-0.0.1.dev260/1password_secrets.egg-info/requires.txt +0 -4
  8. 1password_secrets-0.0.1.dev260/1password_secrets.egg-info/top_level.txt +0 -1
  9. 1password_secrets-0.0.1.dev260/PKG-INFO +0 -150
  10. 1password_secrets-0.0.1.dev260/pyproject.toml +0 -45
  11. 1password_secrets-0.0.1.dev260/setup.cfg +0 -4
  12. 1password_secrets-0.0.1.dev260/setup.py +0 -37
  13. {1password_secrets-0.0.1.dev260 → 1password_secrets-0.0.1.dev266}/onepassword_secrets/__init__.py +0 -0
  14. {1password_secrets-0.0.1.dev260 → 1password_secrets-0.0.1.dev266}/onepassword_secrets/__main__.py +0 -0
  15. {1password_secrets-0.0.1.dev260 → 1password_secrets-0.0.1.dev266}/onepassword_secrets/cli.py +0 -0
  16. {1password_secrets-0.0.1.dev260 → 1password_secrets-0.0.1.dev266}/onepassword_secrets/commands.py +0 -0
  17. {1password_secrets-0.0.1.dev260 → 1password_secrets-0.0.1.dev266}/onepassword_secrets/constants.py +0 -0
  18. {1password_secrets-0.0.1.dev260 → 1password_secrets-0.0.1.dev266}/onepassword_secrets/envs.py +0 -0
  19. {1password_secrets-0.0.1.dev260 → 1password_secrets-0.0.1.dev266}/onepassword_secrets/errors.py +0 -0
  20. {1password_secrets-0.0.1.dev260 → 1password_secrets-0.0.1.dev266}/onepassword_secrets/fly.py +0 -0
  21. {1password_secrets-0.0.1.dev260 → 1password_secrets-0.0.1.dev266}/onepassword_secrets/git.py +0 -0
  22. {1password_secrets-0.0.1.dev260 → 1password_secrets-0.0.1.dev266}/onepassword_secrets/logs.py +0 -0
  23. {1password_secrets-0.0.1.dev260 → 1password_secrets-0.0.1.dev266}/onepassword_secrets/op.py +0 -0
  24. {1password_secrets-0.0.1.dev260 → 1password_secrets-0.0.1.dev266}/onepassword_secrets/prompts.py +0 -0
  25. {1password_secrets-0.0.1.dev260 → 1password_secrets-0.0.1.dev266}/onepassword_secrets/utils.py +0 -0
@@ -1,32 +1,22 @@
1
1
  Metadata-Version: 2.4
2
2
  Name: 1password-secrets
3
- Version: 0.0.1.dev260
3
+ Version: 0.0.1.dev266
4
4
  Summary: 1password-secrets is a set of utilities to sync 1password secrets.
5
- Home-page: https://github.com/significa/fly-1password-secrets
6
- Author: Significa
7
- License: MIT
5
+ License-Expression: MIT
8
6
  Keywords: fly.io,1password,secrets
7
+ Author: Significa
8
+ Requires-Python: >=3.11
9
9
  Classifier: Development Status :: 4 - Beta
10
10
  Classifier: Environment :: Console
11
11
  Classifier: Intended Audience :: Developers
12
12
  Classifier: Topic :: Utilities
13
13
  Classifier: Programming Language :: Python :: 3
14
- Requires-Python: >=3.11
14
+ Requires-Dist: inquirer (==3.4.1)
15
+ Requires-Dist: python-dotenv (==1.2.4)
16
+ Requires-Dist: requests (==2.34.2)
17
+ Requires-Dist: rich (==15.0.0)
18
+ Project-URL: Homepage, https://github.com/significa/fly-1password-secrets
15
19
  Description-Content-Type: text/markdown
16
- Requires-Dist: python-dotenv==1.2.4
17
- Requires-Dist: requests==2.34.2
18
- Requires-Dist: rich==15.0.0
19
- Requires-Dist: inquirer==3.4.1
20
- Dynamic: author
21
- Dynamic: classifier
22
- Dynamic: description
23
- Dynamic: description-content-type
24
- Dynamic: home-page
25
- Dynamic: keywords
26
- Dynamic: license
27
- Dynamic: requires-dist
28
- Dynamic: requires-python
29
- Dynamic: summary
30
20
 
31
21
  [![PyPI version 1password-secrets](https://raw.githubusercontent.com/significa/.github/main/assets/significa-github-banner-small.png)](https://significa.co)
32
22
 
@@ -140,11 +130,11 @@ As with `Local` secrets above, you can specify a single 1Password vault by name
140
130
  ## Development
141
131
 
142
132
  - Ensure you have `make` installed.
143
- - Create a virtual environment: `make setup-venv`.
144
- - Activate the virtual environment: `source ./venv/bin/activate`.
145
- - Install dependencies: `make install-deps`.
133
+ - Install [Poetry](https://python-poetry.org/docs/#installation) (v2+).
134
+ - Install dependencies: `make install-deps` (Poetry creates and manages the virtual environment).
146
135
 
147
136
  Then you can install (link) the repo globally with `make local-install`.
148
137
 
149
138
  Before pushing any changes ensure your code is properly formatted with `make lint`.
150
139
  Auto format the code with `make format`
140
+
@@ -110,9 +110,8 @@ As with `Local` secrets above, you can specify a single 1Password vault by name
110
110
  ## Development
111
111
 
112
112
  - Ensure you have `make` installed.
113
- - Create a virtual environment: `make setup-venv`.
114
- - Activate the virtual environment: `source ./venv/bin/activate`.
115
- - Install dependencies: `make install-deps`.
113
+ - Install [Poetry](https://python-poetry.org/docs/#installation) (v2+).
114
+ - Install dependencies: `make install-deps` (Poetry creates and manages the virtual environment).
116
115
 
117
116
  Then you can install (link) the repo globally with `make local-install`.
118
117
 
@@ -0,0 +1,85 @@
1
+ [project]
2
+ name = "1password-secrets"
3
+ version = "0.0.1.dev266"
4
+ description = "1password-secrets is a set of utilities to sync 1password secrets."
5
+ readme = "README.md"
6
+ requires-python = ">=3.11"
7
+ license = "MIT"
8
+ authors = [{ name = "Significa" }]
9
+ keywords = ["fly.io", "1password", "secrets"]
10
+ classifiers = [
11
+ "Development Status :: 4 - Beta",
12
+ "Environment :: Console",
13
+ "Intended Audience :: Developers",
14
+ "Topic :: Utilities",
15
+ "Programming Language :: Python :: 3",
16
+ ]
17
+ dependencies = [
18
+ "python-dotenv (==1.2.4)",
19
+ "requests (==2.34.2)",
20
+ "rich (==15.0.0)",
21
+ "inquirer (==3.4.1)",
22
+ ]
23
+
24
+ [project.urls]
25
+ Homepage = "https://github.com/significa/fly-1password-secrets"
26
+
27
+ [project.scripts]
28
+ 1password-secrets = "onepassword_secrets:main"
29
+
30
+ [tool.poetry]
31
+ packages = [{ include = "onepassword_secrets" }]
32
+
33
+ [tool.poetry.group.dev.dependencies]
34
+ ruff = "==0.17.6"
35
+ pyright = "==1.1.414"
36
+
37
+ [build-system]
38
+ requires = ["poetry-core>=2.0.0,<3.0.0"]
39
+ build-backend = "poetry.core.masonry.api"
40
+
41
+ [tool.ruff]
42
+ line-length = 100
43
+ target-version = "py311"
44
+ indent-width = 4
45
+
46
+ [tool.ruff.format]
47
+ quote-style = "double"
48
+ indent-style = "space"
49
+
50
+ [tool.ruff.lint]
51
+ select = [
52
+ "C",
53
+ "DTZ",
54
+ "E",
55
+ "F",
56
+ "FLY",
57
+ "G002",
58
+ "G003",
59
+ "G010",
60
+ "G101",
61
+ "I",
62
+ "N",
63
+ "PL",
64
+ "Q",
65
+ "RET",
66
+ "RUF",
67
+ "S",
68
+ "T10",
69
+ "T20",
70
+ "UP",
71
+ "W",
72
+ ]
73
+ ignore = [
74
+ "N805",
75
+ "PLR0912",
76
+ "PLR0913",
77
+ "RUF100",
78
+ "S101",
79
+ "S104",
80
+ "T201",
81
+ ]
82
+ fixable = ["ALL"]
83
+
84
+ [tool.ruff.lint.pycodestyle]
85
+ max-line-length = 120
@@ -1,22 +0,0 @@
1
- README.md
2
- pyproject.toml
3
- setup.py
4
- 1password_secrets.egg-info/PKG-INFO
5
- 1password_secrets.egg-info/SOURCES.txt
6
- 1password_secrets.egg-info/dependency_links.txt
7
- 1password_secrets.egg-info/entry_points.txt
8
- 1password_secrets.egg-info/requires.txt
9
- 1password_secrets.egg-info/top_level.txt
10
- onepassword_secrets/__init__.py
11
- onepassword_secrets/__main__.py
12
- onepassword_secrets/cli.py
13
- onepassword_secrets/commands.py
14
- onepassword_secrets/constants.py
15
- onepassword_secrets/envs.py
16
- onepassword_secrets/errors.py
17
- onepassword_secrets/fly.py
18
- onepassword_secrets/git.py
19
- onepassword_secrets/logs.py
20
- onepassword_secrets/op.py
21
- onepassword_secrets/prompts.py
22
- onepassword_secrets/utils.py
@@ -1,2 +0,0 @@
1
- [console_scripts]
2
- 1password-secrets = onepassword_secrets:main
@@ -1,4 +0,0 @@
1
- python-dotenv==1.2.4
2
- requests==2.34.2
3
- rich==15.0.0
4
- inquirer==3.4.1
@@ -1 +0,0 @@
1
- onepassword_secrets
@@ -1,150 +0,0 @@
1
- Metadata-Version: 2.4
2
- Name: 1password-secrets
3
- Version: 0.0.1.dev260
4
- Summary: 1password-secrets is a set of utilities to sync 1password secrets.
5
- Home-page: https://github.com/significa/fly-1password-secrets
6
- Author: Significa
7
- License: MIT
8
- Keywords: fly.io,1password,secrets
9
- Classifier: Development Status :: 4 - Beta
10
- Classifier: Environment :: Console
11
- Classifier: Intended Audience :: Developers
12
- Classifier: Topic :: Utilities
13
- Classifier: Programming Language :: Python :: 3
14
- Requires-Python: >=3.11
15
- Description-Content-Type: text/markdown
16
- Requires-Dist: python-dotenv==1.2.4
17
- Requires-Dist: requests==2.34.2
18
- Requires-Dist: rich==15.0.0
19
- Requires-Dist: inquirer==3.4.1
20
- Dynamic: author
21
- Dynamic: classifier
22
- Dynamic: description
23
- Dynamic: description-content-type
24
- Dynamic: home-page
25
- Dynamic: keywords
26
- Dynamic: license
27
- Dynamic: requires-dist
28
- Dynamic: requires-python
29
- Dynamic: summary
30
-
31
- [![PyPI version 1password-secrets](https://raw.githubusercontent.com/significa/.github/main/assets/significa-github-banner-small.png)](https://significa.co)
32
-
33
- # 1password-secrets
34
-
35
- [![PyPI version 1password-secrets](https://img.shields.io/pypi/v/1password-secrets.svg)](https://pypi.python.org/pypi/1password-secrets/)
36
- [![CI/CD](https://github.com/significa/1password-secrets/actions/workflows/ci-cd.yaml/badge.svg)](https://github.com/significa/1password-secrets/actions/workflows/ci-cd.yaml)
37
-
38
- 1password-secrets is a CLI utility to sync 1Password secrets (env files). It enables:
39
-
40
- - Seamless sharing of _local_ secrets used for development.
41
- Developers starting out in a project can just use this tool to retrieve the `.env` file needed for
42
- local development.
43
- Likewise it is also simple to push any local changes to the 1password vault.
44
-
45
- - More secure and simpler method of managing Fly.io secrets.
46
- By default, Fly secrets must be managed by `flyctl`. This means that when setting secrets in
47
- production, developers must use `flyctl` to pass credentials via arguments - risking credentials
48
- being stored in their histories. Alternatively, one must write secrets in a file and run
49
- `flyctl secrets import`. This works well, but you must ensure everything is synced to a
50
- secret/password manager and then delete the file.
51
- 1password-secrets enables a leaner management of secrets via 1password. When passing a fly app name, it
52
- automatically finds and imports secrets on 1password to Fly. This way you ensure
53
- developers always keep secrets up-to-date and never in any files on disk.
54
-
55
- Motivation: Using 1password avoids the need for another external secret management tool and keeps
56
- the access control in a centralised place that we already use.
57
-
58
- ## Getting started
59
-
60
- ### Requirements
61
-
62
- - Have the following dependencies: 1Password, Python and optionally fly.
63
- Install them with one command:
64
-
65
- ```sh
66
- brew install --cask 1password 1password-cli && \
67
- brew install flyctl
68
- ```
69
-
70
- Minimum supported versions:
71
- 1Password >= `8.9.13`
72
- 1Password CLI >= `2.13.1`
73
- Python >= `3.11`
74
- flyctl >= `0.0.451` (optional)
75
-
76
- More information and installation instructions for other systems can be found
77
- [in the 1password documentation](https://developer.1password.com/docs/cli/get-started/).
78
-
79
- - Allow 1Password to connect to 1Password-CLI by going to 1Password's `Settings` -> `Developer` ->
80
- `Command-Line Interface (CLI)` and select `Integrate with 1Password CLI`.
81
-
82
- - Sign into your 1Password desktop and if you wish to use the fly integration, also make sure
83
- the CLI is authenticated.
84
-
85
- ### Installation
86
-
87
- In order to keep your system tidy and without conflicts in your global and user packages,
88
- we recommend [pipx](https://github.com/pypa/pipx?tab=readme-ov-file):
89
-
90
- ```
91
- pipx install 1password-secrets
92
- ```
93
-
94
- This should do the trick for all systems.
95
- Adapt the installation command to fit your preferred tool.
96
-
97
- Use `pipx upgrade 1password-secrets` to update to the latest release.
98
-
99
- ## Usage
100
-
101
- ### Local
102
-
103
- 1password-secrets will allow you to `create`, `pull` and `push` secrets to a 1password secure note
104
- with `repo:<owner>/<repo>` or `local:<dir-basename>` in its name. `repo` is used when within a valid
105
- git repository with remote "origin" set.
106
-
107
- The remote name can be changed with the `--remote` switch if you use a different remote
108
- (e.g. `upstream`)
109
-
110
- By default it syncs to `./.env` file, this can be overridden with a `file_name` field in 1password
111
- containing the desired relative file path.
112
-
113
- By default it searches items across 1password vaults. Restrict the search to a single vault with the
114
- `--vault` switch.
115
-
116
- - To bootstrap a 1Password secret matching the current repo/directory, run:
117
- `1password-secrets local create ./env`
118
- Where `./env` is an existing file you want to use.
119
-
120
- - To get secrets from 1Password, run:
121
- `1password-secrets local pull`
122
-
123
- - To push the local changes to 1Password, run:
124
- `1password-secrets local push`
125
-
126
- ### Fly
127
-
128
- Make sure you have a Secure Note in 1Password by having `fly:<fly-app-name>` in the title. `fly-app-name`
129
- is the name of your fly application.
130
-
131
- As with `Local` secrets above, you can specify a single 1Password vault by name or id with the
132
- `--vault` option.
133
-
134
- - To import secrets to fly, run:
135
- `1password-secrets fly import <fly-app-name>`
136
-
137
- - Secrets can be edited directly on the 1Password app or by using the command:
138
- `1password-secrets fly edit <fly-app-name>`
139
-
140
- ## Development
141
-
142
- - Ensure you have `make` installed.
143
- - Create a virtual environment: `make setup-venv`.
144
- - Activate the virtual environment: `source ./venv/bin/activate`.
145
- - Install dependencies: `make install-deps`.
146
-
147
- Then you can install (link) the repo globally with `make local-install`.
148
-
149
- Before pushing any changes ensure your code is properly formatted with `make lint`.
150
- Auto format the code with `make format`
@@ -1,45 +0,0 @@
1
- [tool.ruff]
2
- line-length = 100
3
- target-version = "py311"
4
- indent-width = 4
5
-
6
- [tool.ruff.format]
7
- quote-style = "double"
8
- indent-style = "space"
9
-
10
- [tool.ruff.lint]
11
- select = [
12
- "C",
13
- "DTZ",
14
- "E",
15
- "F",
16
- "FLY",
17
- "G002",
18
- "G003",
19
- "G010",
20
- "G101",
21
- "I",
22
- "N",
23
- "PL",
24
- "Q",
25
- "RET",
26
- "RUF",
27
- "S",
28
- "T10",
29
- "T20",
30
- "UP",
31
- "W",
32
- ]
33
- ignore = [
34
- "N805",
35
- "PLR0912",
36
- "PLR0913",
37
- "RUF100",
38
- "S101",
39
- "S104",
40
- "T201",
41
- ]
42
- fixable = ["ALL"]
43
-
44
- [tool.ruff.lint.pycodestyle]
45
- max-line-length = 120
@@ -1,4 +0,0 @@
1
- [egg_info]
2
- tag_build =
3
- tag_date = 0
4
-
@@ -1,37 +0,0 @@
1
- import os
2
- import re
3
- from pathlib import Path
4
-
5
- from setuptools import setup # type: ignore
6
-
7
- long_description = (Path(__file__).parent / "README.md").read_text()
8
- requirements = (Path(__file__).parent / "requirements.txt").read_text().split("\n")
9
-
10
- version = re.sub(r"^v", "", os.getenv("VERSION", "v0.1.0-dev"))
11
-
12
- print(f"Publishing version {version}")
13
-
14
- setup(
15
- name="1password-secrets",
16
- python_requires=">=3.11",
17
- version=version,
18
- description="1password-secrets is a set of utilities to sync 1password secrets.",
19
- long_description=long_description,
20
- long_description_content_type="text/markdown",
21
- install_requires=requirements,
22
- packages=["onepassword_secrets"],
23
- entry_points={
24
- "console_scripts": ["1password-secrets = onepassword_secrets:main"],
25
- },
26
- license="MIT",
27
- url="https://github.com/significa/fly-1password-secrets",
28
- keywords="fly.io, 1password, secrets",
29
- author="Significa",
30
- classifiers=[
31
- "Development Status :: 4 - Beta",
32
- "Environment :: Console",
33
- "Intended Audience :: Developers",
34
- "Topic :: Utilities",
35
- "Programming Language :: Python :: 3",
36
- ],
37
- )