Re: [OE-core] [PATCHv2 3/5] devtool: Make use of oe.patch.GitApplyTree.commitIgnored()

2024-02-19 Thread Peter Kjellerstedt
> -Original Message-
> From: Ross Burton 
> Sent: den 19 februari 2024 13:54
> To: Peter Kjellerstedt 
> Cc: openembedded-core@lists.openembedded.org
> Subject: Re: [OE-core] [PATCHv2 3/5] devtool: Make use of
> oe.patch.GitApplyTree.commitIgnored()
> 
> On 19 Feb 2024, at 01:28, Peter Kjellerstedt via lists.openembedded.org
>  wrote:
> >
> > This makes use of the oe.patch.GitApplyTree.commitIgnored() function to
> > create commits that shall be ignored by `devtool finish`.
> 
> If we’re using notes to store the filename info, couldn’t the ignores
> state also be a note?
> 
> Ross

Yes, that comes with patch 5. This was just a preparation to get the three 
different places that create ignore commits gathered into one place.

//Peter


-=-=-=-=-=-=-=-=-=-=-=-
Links: You receive all messages sent to this group.
View/Reply Online (#195879): 
https://lists.openembedded.org/g/openembedded-core/message/195879
Mute This Topic: https://lists.openembedded.org/mt/104439181/21656
Group Owner: openembedded-core+ow...@lists.openembedded.org
Unsubscribe: https://lists.openembedded.org/g/openembedded-core/unsub 
[arch...@mail-archive.com]
-=-=-=-=-=-=-=-=-=-=-=-



Re: [OE-core] [PATCHv2 3/5] devtool: Make use of oe.patch.GitApplyTree.commitIgnored()

2024-02-19 Thread Ross Burton
On 19 Feb 2024, at 01:28, Peter Kjellerstedt via lists.openembedded.org 
 wrote:
> 
> This makes use of the oe.patch.GitApplyTree.commitIgnored() function to
> create commits that shall be ignored by `devtool finish`.

If we’re using notes to store the filename info, couldn’t the ignores state 
also be a note?

Ross
-=-=-=-=-=-=-=-=-=-=-=-
Links: You receive all messages sent to this group.
View/Reply Online (#195872): 
https://lists.openembedded.org/g/openembedded-core/message/195872
Mute This Topic: https://lists.openembedded.org/mt/104439181/21656
Group Owner: openembedded-core+ow...@lists.openembedded.org
Unsubscribe: https://lists.openembedded.org/g/openembedded-core/unsub 
[arch...@mail-archive.com]
-=-=-=-=-=-=-=-=-=-=-=-



[OE-core] [PATCHv2 3/5] devtool: Make use of oe.patch.GitApplyTree.commitIgnored()

2024-02-18 Thread Peter Kjellerstedt
This makes use of the oe.patch.GitApplyTree.commitIgnored() function to
create commits that shall be ignored by `devtool finish`.

Signed-off-by: Peter Kjellerstedt 
---

PATCHv2: No changes.

 scripts/lib/devtool/__init__.py | 4 +---
 scripts/lib/devtool/standard.py | 6 +-
 2 files changed, 2 insertions(+), 8 deletions(-)

diff --git a/scripts/lib/devtool/__init__.py b/scripts/lib/devtool/__init__.py
index c7fc3cfc41..6133c1c5b4 100644
--- a/scripts/lib/devtool/__init__.py
+++ b/scripts/lib/devtool/__init__.py
@@ -253,9 +253,7 @@ def setup_git_repo(repodir, version, devbranch, 
basetag='devtool-base', d=None):
 bb.process.run('git submodule add %s %s' % (remote_url, 
os.path.relpath(root, os.path.join(root, ".."))), cwd=os.path.join(root, ".."))
 found = True
 if found:
-useroptions = []
-oe.patch.GitApplyTree.gitCommandUserOptions(useroptions, 
d=d)
-bb.process.run('git %s commit -m "Adding additionnal 
submodule from SRC_URI\n\n%s"' % (' '.join(useroptions), 
oe.patch.GitApplyTree.ignore_commit_prefix), cwd=os.path.join(root, ".."))
+oe.patch.GitApplyTree.commitIgnored("Add additional 
submodule from SRC_URI", dir=os.path.join(root, ".."), d=d)
 found = False
 if os.path.exists(os.path.join(repodir, '.gitmodules')):
 bb.process.run('git submodule foreach --recursive  "git tag -f %s"' % 
basetag, cwd=repodir)
diff --git a/scripts/lib/devtool/standard.py b/scripts/lib/devtool/standard.py
index ccb7ea851b..6d7fd17fbd 100644
--- a/scripts/lib/devtool/standard.py
+++ b/scripts/lib/devtool/standard.py
@@ -484,11 +484,7 @@ def symlink_oelocal_files_srctree(rd, srctree):
 os.symlink('oe-local-files/%s' % fn, destpth)
 addfiles.append(os.path.join(relpth, fn))
 if addfiles:
-bb.process.run('git add %s' % ' '.join(addfiles), cwd=srctree)
-useroptions = []
-oe.patch.GitApplyTree.gitCommandUserOptions(useroptions, d=rd)
-bb.process.run('git %s commit -m "Committing local file 
symlinks\n\n%s"' % (' '.join(useroptions), 
oe.patch.GitApplyTree.ignore_commit_prefix), cwd=srctree)
-
+oe.patch.GitApplyTree.commitIgnored("Add local file symlinks", 
dir=srctree, files=addfiles, d=rd)
 
 def _extract_source(srctree, keep_temp, devbranch, sync, config, basepath, 
workspace, fixed_setup, d, tinfoil, no_overrides=False):
 """Extract sources of a recipe"""

-=-=-=-=-=-=-=-=-=-=-=-
Links: You receive all messages sent to this group.
View/Reply Online (#195856): 
https://lists.openembedded.org/g/openembedded-core/message/195856
Mute This Topic: https://lists.openembedded.org/mt/104439181/21656
Group Owner: openembedded-core+ow...@lists.openembedded.org
Unsubscribe: https://lists.openembedded.org/g/openembedded-core/unsub 
[arch...@mail-archive.com]
-=-=-=-=-=-=-=-=-=-=-=-