diff options
| author | Jermain Horsman <jermain.horsman@nedap.com> | 2023-11-02 13:11:32 +0100 |
|---|---|---|
| committer | Steve Sakoman <steve@sakoman.com> | 2023-12-05 11:51:37 -1000 |
| commit | b680a95e6b8e0e69e19b38400b33bba3ad45be1c (patch) | |
| tree | 50e5c546371d79f138523c82ce05d84224848efc | |
| parent | 38e5d2ac607ed9abc7b59834d775bf39600e18bf (diff) | |
| download | poky-b680a95e6b8e0e69e19b38400b33bba3ad45be1c.tar.gz | |
lib/oe/buildcfg.py: Remove unused parameter
Several functions included the 'd' parameter but never used it,
additionally the value passed is always None.
(From OE-Core rev: ea871e7920726c7b2e57161092e21c62e6a5d91e)
Signed-off-by: Jermain Horsman <jermain.horsman@nedap.com>
Signed-off-by: Alexandre Belloni <alexandre.belloni@bootlin.com>
(cherry picked from commit 9e03ce0426576ebef3739dc1dfec4f7cd73ae094)
Signed-off-by: Steve Sakoman <steve@sakoman.com>
| -rw-r--r-- | meta/lib/oe/buildcfg.py | 10 |
1 files changed, 5 insertions, 5 deletions
diff --git a/meta/lib/oe/buildcfg.py b/meta/lib/oe/buildcfg.py index b9d32c7cc1..b3fe510309 100644 --- a/meta/lib/oe/buildcfg.py +++ b/meta/lib/oe/buildcfg.py | |||
| @@ -5,23 +5,23 @@ import bb.process | |||
| 5 | 5 | ||
| 6 | def detect_revision(d): | 6 | def detect_revision(d): |
| 7 | path = get_scmbasepath(d) | 7 | path = get_scmbasepath(d) |
| 8 | return get_metadata_git_revision(path, d) | 8 | return get_metadata_git_revision(path) |
| 9 | 9 | ||
| 10 | def detect_branch(d): | 10 | def detect_branch(d): |
| 11 | path = get_scmbasepath(d) | 11 | path = get_scmbasepath(d) |
| 12 | return get_metadata_git_branch(path, d) | 12 | return get_metadata_git_branch(path) |
| 13 | 13 | ||
| 14 | def get_scmbasepath(d): | 14 | def get_scmbasepath(d): |
| 15 | return os.path.join(d.getVar('COREBASE'), 'meta') | 15 | return os.path.join(d.getVar('COREBASE'), 'meta') |
| 16 | 16 | ||
| 17 | def get_metadata_git_branch(path, d): | 17 | def get_metadata_git_branch(path): |
| 18 | try: | 18 | try: |
| 19 | rev, _ = bb.process.run('git rev-parse --abbrev-ref HEAD', cwd=path) | 19 | rev, _ = bb.process.run('git rev-parse --abbrev-ref HEAD', cwd=path) |
| 20 | except bb.process.ExecutionError: | 20 | except bb.process.ExecutionError: |
| 21 | rev = '<unknown>' | 21 | rev = '<unknown>' |
| 22 | return rev.strip() | 22 | return rev.strip() |
| 23 | 23 | ||
| 24 | def get_metadata_git_revision(path, d): | 24 | def get_metadata_git_revision(path): |
| 25 | try: | 25 | try: |
| 26 | rev, _ = bb.process.run('git rev-parse HEAD', cwd=path) | 26 | rev, _ = bb.process.run('git rev-parse HEAD', cwd=path) |
| 27 | except bb.process.ExecutionError: | 27 | except bb.process.ExecutionError: |
| @@ -46,5 +46,5 @@ def get_layer_revisions(d): | |||
| 46 | layers = (d.getVar("BBLAYERS") or "").split() | 46 | layers = (d.getVar("BBLAYERS") or "").split() |
| 47 | revisions = [] | 47 | revisions = [] |
| 48 | for i in layers: | 48 | for i in layers: |
| 49 | revisions.append((i, os.path.basename(i), get_metadata_git_branch(i, None).strip(), get_metadata_git_revision(i, None), is_layer_modified(i))) | 49 | revisions.append((i, os.path.basename(i), get_metadata_git_branch(i).strip(), get_metadata_git_revision(i), is_layer_modified(i))) |
| 50 | return revisions | 50 | return revisions |
