[kirkstone][PATCH] npm.bbclass: avoid DeprecationWarning with new python

Martin Jansa
2023-08-03T01:01:44Z

meta/classes-recipe/npm.bbclass:85: DeprecationWarning: invalid escape sequence '\.'
'--transform', 's,^\./,package/,',

Signed-off-by: Martin Jansa <Martin.Jansa@gmail.com>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
---
meta/classes/npm.bbclass | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/meta/classes/npm.bbclass b/meta/classes/npm.bbclass
index 8379c7b988..45e6b4fac7 100644
--- a/meta/classes/npm.bbclass
+++ b/meta/classes/npm.bbclass
@@ -82,7 +82,7 @@ def npm_pack(env, srcdir, workdir):
subprocess.run(['tar', 'czf', tarball,
'--exclude', './node-modules',
'--exclude-vcs',
- '--transform', 's,^\./,package/,',
+ '--transform', r's,^\./,package/,',
'--mtime', '1985-10-26T08:15:00.000Z',
'.'],
check = True, cwd = srcdir)
--
2.41.0