Skip to content
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
25 changes: 25 additions & 0 deletions .github/workflows/codespell.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,25 @@
# Codespell configuration is within pyproject.toml
---
name: Codespell

on:
push:
branches: [main]
pull_request:
branches: [main]

permissions:
contents: read

jobs:
codespell:
name: Check for spelling errors
runs-on: ubuntu-latest

steps:
- name: Checkout
uses: actions/checkout@v4
- name: Annotate locations with typos
uses: codespell-project/codespell-problem-matcher@v1
- name: Codespell
uses: codespell-project/actions-codespell@v2
5 changes: 5 additions & 0 deletions .pre-commit-config.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -22,3 +22,8 @@ repos:
rev: 6.1.0
hooks:
- id: flake8
- repo: https://github.com/codespell-project/codespell
# Configuration for codespell is in .pre-commit-config.yaml
rev: v2.4.1
hooks:
- id: codespell
2 changes: 1 addition & 1 deletion docs/getting_started/developer-guide.md
Original file line number Diff line number Diff line change
Expand Up @@ -124,7 +124,7 @@ $ pip install -e .

# Now docs dependencies
cd docs
pip install -r requrements.txt
pip install -r requirements.txt

# Build the docs into _build/html
make html
Expand Down
2 changes: 1 addition & 1 deletion docs/getting_started/user-guide.md
Original file line number Diff line number Diff line change
Expand Up @@ -11,7 +11,7 @@ or jump to our [developer guide](developer-guide.md) to learn about running test
or contributing to the project. If you want to create your own client, you likely want to:


1. Start a local registry (described below), or have access to an ORAS [supported registry](https://oras.land/implementors/#docker-distribution)
1. Start a local registry (described below), or have access to an ORAS [supported registry](https://oras.land/docs/compatible_oci_registries)
Copy link
Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

note -- I entirely replaced 404ing URL

2. Decide on the context for your code (e.g., it's easy to start with Python functions in a single file and move to a client setup if appropriate for your tool)
3. Subclass the `oras.provider.Registry` for your custom class (examples below!)
4. Add custom functions to push, pull, or create manifests / layers
Expand Down
2 changes: 1 addition & 1 deletion oras/container.py
Original file line number Diff line number Diff line change
Expand Up @@ -30,7 +30,7 @@ def __init__(self, name: str, registry: Optional[str] = None):
"""
self.registry = registry or oras.defaults.registry.index_name

# Registry is the name takes precendence
# Registry is the name takes precedence
self.parse(name)

@property
Expand Down
2 changes: 1 addition & 1 deletion oras/tests/test_oras.py
Original file line number Diff line number Diff line change
Expand Up @@ -95,7 +95,7 @@ def test_basic_push_pul_via_sha_ref(tmp_path, registry, credentials, target):
@pytest.mark.with_auth(False)
def test_get_delete_tags(tmp_path, registry, credentials, target):
"""
Test creationg, getting, and deleting tags.
Test creating, getting, and deleting tags.
"""
client = oras.client.OrasClient(hostname=registry, insecure=True)
artifact = os.path.join(here, "artifact.txt")
Expand Down
2 changes: 1 addition & 1 deletion oras/utils/fileio.py
Original file line number Diff line number Diff line change
Expand Up @@ -255,7 +255,7 @@ def write_file(
"""
Write content to a filename

:param filename: filname to write
:param filename: filename to write
:type filename: str
:param content: content to write
:type content: str
Expand Down
7 changes: 7 additions & 0 deletions pyproject.toml
Original file line number Diff line number Diff line change
Expand Up @@ -11,3 +11,10 @@ mypy_path = ["oras", "examples"]

[tool.pytest.ini_options]
markers = ["with_auth: mark for tests requiring authenticated registry access (or not)"]

[tool.codespell]
# Ref: https://github.com/codespell-project/codespell#using-a-config-file
skip = '.git*,*.css'
check-hidden = true
# ignore-regex = ''
ignore-words-list = 'pakages'