Skip to content

Commit

Permalink
Merge pull request #934 from cderici/licence-headers-forward-port
Browse files Browse the repository at this point in the history
#934

#### Description

This is a forward port of #933, adding license headers to source files:

```python
# Copyright 2023 Canonical Ltd.
# Licensed under the Apache V2, see LICENCE file for details.
```

#### QA Steps

No behavior change.
  • Loading branch information
jujubot committed Aug 23, 2023
2 parents 16b9c9b + 6c1cbc9 commit 28f31fa
Show file tree
Hide file tree
Showing 139 changed files with 458 additions and 67 deletions.
4 changes: 3 additions & 1 deletion .github/workflows/test.yaml
Expand Up @@ -21,7 +21,9 @@ jobs:
- name: Install dependencies
run: pip install tox
- name: Run linter
run: tox -e lint
run: |
tox -e lint
./scripts/copyright.sh
unit-tests:
needs: lint
Expand Down
4 changes: 3 additions & 1 deletion Makefile
Expand Up @@ -25,7 +25,9 @@ test: lint
tox -e integration

.PHONY: lint
lint:
lint:
@./scripts/copyright.sh
@echo "==> Running flake8 linter"
tox -e lint

.PHONY: docs
Expand Down
3 changes: 3 additions & 0 deletions docs/conf.py
@@ -1,3 +1,6 @@
# Copyright 2023 Canonical Ltd.
# Licensed under the Apache V2, see LICENCE file for details.

# -*- coding: utf-8 -*-
#
# libjuju documentation build configuration file, created by
Expand Down
3 changes: 3 additions & 0 deletions examples/action.py
@@ -1,3 +1,6 @@
# Copyright 2023 Canonical Ltd.
# Licensed under the Apache V2, see LICENCE file for details.

"""
This example:
Expand Down
3 changes: 3 additions & 0 deletions examples/add_k8s.py
@@ -1,3 +1,6 @@
# Copyright 2023 Canonical Ltd.
# Licensed under the Apache V2, see LICENCE file for details.

"""
This example:
Expand Down
3 changes: 3 additions & 0 deletions examples/add_machine.py
@@ -1,5 +1,8 @@
#!/usr/bin/env python3

# Copyright 2023 Canonical Ltd.
# Licensed under the Apache V2, see LICENCE file for details.

"""
This example:
Expand Down
3 changes: 3 additions & 0 deletions examples/add_model.py
@@ -1,3 +1,6 @@
# Copyright 2023 Canonical Ltd.
# Licensed under the Apache V2, see LICENCE file for details.

"""
This example:
Expand Down
3 changes: 3 additions & 0 deletions examples/add_secrets_backend.py
@@ -1,3 +1,6 @@
# Copyright 2023 Canonical Ltd.
# Licensed under the Apache V2, see LICENCE file for details.

from juju import jasyncio
from juju.model import Model

Expand Down
3 changes: 3 additions & 0 deletions examples/allwatcher.py
@@ -1,3 +1,6 @@
# Copyright 2023 Canonical Ltd.
# Licensed under the Apache V2, see LICENCE file for details.

"""
This example:
Expand Down
3 changes: 3 additions & 0 deletions examples/charmhub_deploy_k8s.py
@@ -1,3 +1,6 @@
# Copyright 2023 Canonical Ltd.
# Licensed under the Apache V2, see LICENCE file for details.

"""
This example:
Expand Down
3 changes: 3 additions & 0 deletions examples/charmhub_deploy_machine.py
@@ -1,3 +1,6 @@
# Copyright 2023 Canonical Ltd.
# Licensed under the Apache V2, see LICENCE file for details.

"""
This example:
Expand Down
3 changes: 3 additions & 0 deletions examples/charmhub_find.py
@@ -1,3 +1,6 @@
# Copyright 2023 Canonical Ltd.
# Licensed under the Apache V2, see LICENCE file for details.

"""
Example to show how to connect to the current model and search the charm-hub
repository for charms.
Expand Down
3 changes: 3 additions & 0 deletions examples/charmhub_info.py
@@ -1,3 +1,6 @@
# Copyright 2023 Canonical Ltd.
# Licensed under the Apache V2, see LICENCE file for details.

"""
Example to show how to connect to the current model and query the charm-hub
repository for information about a given charm.
Expand Down
3 changes: 3 additions & 0 deletions examples/cloud.py
@@ -1,3 +1,6 @@
# Copyright 2023 Canonical Ltd.
# Licensed under the Apache V2, see LICENCE file for details.

"""
This example:
Expand Down
3 changes: 3 additions & 0 deletions examples/clouds.py
@@ -1,3 +1,6 @@
# Copyright 2023 Canonical Ltd.
# Licensed under the Apache V2, see LICENCE file for details.

"""
This example:
Expand Down
3 changes: 3 additions & 0 deletions examples/config.py
@@ -1,3 +1,6 @@
# Copyright 2023 Canonical Ltd.
# Licensed under the Apache V2, see LICENCE file for details.

"""
This example:
Expand Down
3 changes: 3 additions & 0 deletions examples/connect_current_model.py
@@ -1,3 +1,6 @@
# Copyright 2023 Canonical Ltd.
# Licensed under the Apache V2, see LICENCE file for details.

"""
This is a very basic example that connects to the currently selected model
and prints the number of applications deployed to it.
Expand Down
3 changes: 3 additions & 0 deletions examples/controller.py
@@ -1,3 +1,6 @@
# Copyright 2023 Canonical Ltd.
# Licensed under the Apache V2, see LICENCE file for details.

"""
This example:
Expand Down
3 changes: 3 additions & 0 deletions examples/credential.py
@@ -1,3 +1,6 @@
# Copyright 2023 Canonical Ltd.
# Licensed under the Apache V2, see LICENCE file for details.

import sys
from juju import jasyncio
from juju.controller import Controller
Expand Down
3 changes: 3 additions & 0 deletions examples/crossmodel.py
@@ -1,3 +1,6 @@
# Copyright 2023 Canonical Ltd.
# Licensed under the Apache V2, see LICENCE file for details.

"""
This example:
Expand Down
3 changes: 3 additions & 0 deletions examples/crossmodel_bundle.py
@@ -1,3 +1,6 @@
# Copyright 2023 Canonical Ltd.
# Licensed under the Apache V2, see LICENCE file for details.

"""
This example:
Expand Down
3 changes: 3 additions & 0 deletions examples/crossmodel_controller.py
@@ -1,3 +1,6 @@
# Copyright 2023 Canonical Ltd.
# Licensed under the Apache V2, see LICENCE file for details.

"""
This example:
Expand Down
3 changes: 3 additions & 0 deletions examples/crossmodel_relation.py
@@ -1,3 +1,6 @@
# Copyright 2023 Canonical Ltd.
# Licensed under the Apache V2, see LICENCE file for details.

"""
This example:
Expand Down
3 changes: 3 additions & 0 deletions examples/debug-log.py
@@ -1,3 +1,6 @@
# Copyright 2023 Canonical Ltd.
# Licensed under the Apache V2, see LICENCE file for details.

"""
This example demonstrate how debug-log works
Expand Down
3 changes: 3 additions & 0 deletions examples/deploy.py
@@ -1,3 +1,6 @@
# Copyright 2023 Canonical Ltd.
# Licensed under the Apache V2, see LICENCE file for details.

"""
This example:
Expand Down
3 changes: 3 additions & 0 deletions examples/deploy_bundle.py
@@ -1,3 +1,6 @@
# Copyright 2023 Canonical Ltd.
# Licensed under the Apache V2, see LICENCE file for details.

"""
This example:
Expand Down
3 changes: 3 additions & 0 deletions examples/deploy_bundle_charmhub.py
@@ -1,3 +1,6 @@
# Copyright 2023 Canonical Ltd.
# Licensed under the Apache V2, see LICENCE file for details.

"""
This example:
1. Connects to the current model
Expand Down
3 changes: 3 additions & 0 deletions examples/deploy_bundle_with_trust.py
@@ -1,3 +1,6 @@
# Copyright 2023 Canonical Ltd.
# Licensed under the Apache V2, see LICENCE file for details.

"""
This example:
Expand Down
3 changes: 3 additions & 0 deletions examples/deploy_constraints.py
@@ -1,3 +1,6 @@
# Copyright 2023 Canonical Ltd.
# Licensed under the Apache V2, see LICENCE file for details.

"""
This example:
Expand Down
3 changes: 3 additions & 0 deletions examples/deploy_local_big_k8s_bundle.py
@@ -1,3 +1,6 @@
# Copyright 2023 Canonical Ltd.
# Licensed under the Apache V2, see LICENCE file for details.

"""
This example:
Expand Down
3 changes: 3 additions & 0 deletions examples/deploy_local_bundle_with_resources.py
@@ -1,3 +1,6 @@
# Copyright 2023 Canonical Ltd.
# Licensed under the Apache V2, see LICENCE file for details.

"""
This example:
Expand Down
3 changes: 3 additions & 0 deletions examples/deploy_local_file_resource.py
@@ -1,3 +1,6 @@
# Copyright 2023 Canonical Ltd.
# Licensed under the Apache V2, see LICENCE file for details.

"""
This example:
Expand Down
3 changes: 3 additions & 0 deletions examples/deploy_local_resource.py
@@ -1,3 +1,6 @@
# Copyright 2023 Canonical Ltd.
# Licensed under the Apache V2, see LICENCE file for details.

"""
This example:
Expand Down
3 changes: 3 additions & 0 deletions examples/deploy_with_revision.py
@@ -1,3 +1,6 @@
# Copyright 2023 Canonical Ltd.
# Licensed under the Apache V2, see LICENCE file for details.

from juju import jasyncio
from juju.model import Model

Expand Down
3 changes: 3 additions & 0 deletions examples/expose-application.py
@@ -1,3 +1,6 @@
# Copyright 2023 Canonical Ltd.
# Licensed under the Apache V2, see LICENCE file for details.

"""
This example:
Expand Down
3 changes: 3 additions & 0 deletions examples/formatted_status.py
@@ -1,3 +1,6 @@
# Copyright 2023 Canonical Ltd.
# Licensed under the Apache V2, see LICENCE file for details.

"""
This example demonstrates how to obtain a formatted full status
description. For a similar solution using the FullStatus object
Expand Down
3 changes: 3 additions & 0 deletions examples/fullstatus.py
@@ -1,3 +1,6 @@
# Copyright 2023 Canonical Ltd.
# Licensed under the Apache V2, see LICENCE file for details.

from juju import jasyncio
from juju.model import Model

Expand Down
3 changes: 3 additions & 0 deletions examples/future.py
@@ -1,3 +1,6 @@
# Copyright 2023 Canonical Ltd.
# Licensed under the Apache V2, see LICENCE file for details.

"""
This example doesn't work - it demonstrates features that don't exist yet.
Expand Down
3 changes: 3 additions & 0 deletions examples/get_cloud.py
@@ -1,3 +1,6 @@
# Copyright 2023 Canonical Ltd.
# Licensed under the Apache V2, see LICENCE file for details.

"""
This example:
Expand Down
3 changes: 3 additions & 0 deletions examples/leadership.py
@@ -1,3 +1,6 @@
# Copyright 2023 Canonical Ltd.
# Licensed under the Apache V2, see LICENCE file for details.

"""
This example:
Expand Down
3 changes: 3 additions & 0 deletions examples/list_secrets.py
@@ -1,3 +1,6 @@
# Copyright 2023 Canonical Ltd.
# Licensed under the Apache V2, see LICENCE file for details.

from juju import jasyncio
from juju.model import Model

Expand Down
3 changes: 3 additions & 0 deletions examples/livemodel.py
@@ -1,3 +1,6 @@
# Copyright 2023 Canonical Ltd.
# Licensed under the Apache V2, see LICENCE file for details.

"""
This example:
Expand Down
3 changes: 3 additions & 0 deletions examples/local_refresh.py
@@ -1,3 +1,6 @@
# Copyright 2023 Canonical Ltd.
# Licensed under the Apache V2, see LICENCE file for details.

"""
This example:
Expand Down
3 changes: 3 additions & 0 deletions examples/localcharm.py
@@ -1,3 +1,6 @@
# Copyright 2023 Canonical Ltd.
# Licensed under the Apache V2, see LICENCE file for details.

"""
This example shows how to deploy a local charm. It:
Expand Down
4 changes: 4 additions & 0 deletions examples/machine_hostname.py
@@ -1,5 +1,9 @@
#!/usr/bin/env python3

# Copyright 2023 Canonical Ltd.
# Licensed under the Apache V2, see LICENCE file for details.


"""
This example:
Expand Down
3 changes: 3 additions & 0 deletions examples/model.py
@@ -1,3 +1,6 @@
# Copyright 2023 Canonical Ltd.
# Licensed under the Apache V2, see LICENCE file for details.

"""
This example shows how to reconnect to a model if you encounter an error
Expand Down
3 changes: 3 additions & 0 deletions examples/modelsummaries.py
@@ -1,3 +1,6 @@
# Copyright 2023 Canonical Ltd.
# Licensed under the Apache V2, see LICENCE file for details.

"""
This example:
Expand Down
3 changes: 3 additions & 0 deletions examples/relate.py
@@ -1,3 +1,6 @@
# Copyright 2023 Canonical Ltd.
# Licensed under the Apache V2, see LICENCE file for details.

"""
This example:
Expand Down
2 changes: 2 additions & 0 deletions examples/run_action.py
@@ -1,3 +1,5 @@
# Copyright 2023 Canonical Ltd.
# Licensed under the Apache V2, see LICENCE file for details.

from juju import jasyncio
from juju.model import Model
Expand Down
3 changes: 3 additions & 0 deletions examples/scp.py
@@ -1,3 +1,6 @@
# Copyright 2023 Canonical Ltd.
# Licensed under the Apache V2, see LICENCE file for details.

"""
This is a very basic example that connects to the currently selected model
and prints the number of applications deployed to it.
Expand Down
3 changes: 3 additions & 0 deletions examples/status.py
@@ -1,3 +1,6 @@
# Copyright 2023 Canonical Ltd.
# Licensed under the Apache V2, see LICENCE file for details.

"""
This example demonstrate how status works

Expand Down
3 changes: 3 additions & 0 deletions examples/unitrun.py
@@ -1,3 +1,6 @@
# Copyright 2023 Canonical Ltd.
# Licensed under the Apache V2, see LICENCE file for details.

"""
This example:

Expand Down
3 changes: 3 additions & 0 deletions examples/upgrade_local_charm_k8s.py
@@ -1,3 +1,6 @@
# Copyright 2023 Canonical Ltd.
# Licensed under the Apache V2, see LICENCE file for details.

"""
This example:

Expand Down
2 changes: 2 additions & 0 deletions juju/access.py
@@ -1,3 +1,5 @@
# Copyright 2023 Canonical Ltd.
# Licensed under the Apache V2, see LICENCE file for details.

from .errors import JujuNotValid

Expand Down
3 changes: 3 additions & 0 deletions juju/action.py
@@ -1,3 +1,6 @@
# Copyright 2023 Canonical Ltd.
# Licensed under the Apache V2, see LICENCE file for details.

from . import model


Expand Down

0 comments on commit 28f31fa

Please sign in to comment.