Escaping does not work in my use case. It must be escaped for python, ssh and shell as well as for different versions of echo. Let's try it a little less elegant, but hopefully more reliable.
Signed-off-by: Adrian Freihofer <adrian.freiho...@siemens.com> --- scripts/oe-publish-sdk | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/scripts/oe-publish-sdk b/scripts/oe-publish-sdk index 4b70f436b1..19a5d69864 100755 --- a/scripts/oe-publish-sdk +++ b/scripts/oe-publish-sdk @@ -106,7 +106,7 @@ def publish(args): if not is_remote: cmd = 'set -e; mkdir -p %s/layers; cd %s/layers; if [ ! -e .git ]; then git init .; cp .git/hooks/post-update.sample .git/hooks/post-commit; echo "*.pyc\n*.pyo\npyshtables.py" > .gitignore; fi; git add -A .; git config user.email "o...@oe.oe" && git config user.name "OE" && git commit -q -m "init repo" || true' % (destination, destination) else: - cmd = "ssh %s 'set -e; mkdir -p %s/layers; cd %s/layers; if [ ! -e .git ]; then git init .; cp .git/hooks/post-update.sample .git/hooks/post-commit; echo '*.pyc\n*.pyo\npyshtables.py' > .gitignore; fi; git add -A .; git config user.email 'o...@oe.oe' && git config user.name 'OE' && git commit -q -m \"init repo\" || true'" % (host, destdir, destdir) + cmd = "ssh %s 'set -e; mkdir -p %s/layers; cd %s/layers; if [ ! -e .git ]; then git init .; cp .git/hooks/post-update.sample .git/hooks/post-commit; echo '*.pyc' > .gitignore; echo '*.pyo' >> .gitignore; echo 'pyshtables.py' >> .gitignore; fi; git add -A .; git config user.email 'o...@oe.oe' && git config user.name 'OE' && git commit -q -m \"init repo\" || true'" % (host, destdir, destdir) ret = subprocess.call(cmd, shell=True) if ret == 0: logger.info('SDK published successfully') -- 2.26.2
-=-=-=-=-=-=-=-=-=-=-=- Links: You receive all messages sent to this group. View/Reply Online (#142204): https://lists.openembedded.org/g/openembedded-core/message/142204 Mute This Topic: https://lists.openembedded.org/mt/76690490/21656 Group Owner: openembedded-core+ow...@lists.openembedded.org Unsubscribe: https://lists.openembedded.org/g/openembedded-core/unsub [arch...@mail-archive.com] -=-=-=-=-=-=-=-=-=-=-=-