From: "Juraj Linkeš" <juraj.linkes@pantheon.tech>
To: thomas@monjalon.net, david.marchand@redhat.com,
Honnappa.Nagarahalli@arm.com, ohilyard@iol.unh.edu,
lijuan.tu@intel.com
Cc: dev@dpdk.org, "Juraj Linkeš" <juraj.linkes@pantheon.tech>
Subject: [RFC PATCH v1 1/8] dts: merge DTS format.sh to DPDK
Date: Wed, 6 Apr 2022 15:31:44 +0000 [thread overview]
Message-ID: <20220406153151.2917346-2-juraj.linkes@pantheon.tech> (raw)
In-Reply-To: <20220406153151.2917346-1-juraj.linkes@pantheon.tech>
---
dts/format.sh | 35 +++++++++++++++++++++++++++++++++++
1 file changed, 35 insertions(+)
create mode 100755 dts/format.sh
diff --git a/dts/format.sh b/dts/format.sh
new file mode 100755
index 0000000000..d35c0bf1da
--- /dev/null
+++ b/dts/format.sh
@@ -0,0 +1,35 @@
+#!/usr/bin/env bash
+
+function main() {
+ # The directory to work on is either passed in as argument 1,
+ # or is the current working directory
+ DIRECTORY=${1:-`pwd`}
+ LINE_LENGTH=88
+
+ isort \
+ --overwrite-in-place \
+ --profile black \
+ -j `nproc` \
+ --line-length $LINE_LENGTH \
+ --python-version auto \
+ $DIRECTORY
+
+ black \
+ --line-length $LINE_LENGTH \
+ --required-version 22.1.0 \
+ --target-version py38 \
+ --safe \
+ $DIRECTORY
+}
+
+function help() {
+ echo "usage: format.sh <directory>"
+}
+
+if [ "$1" == "-h" ] || [ "$1" == "--help" ]; then
+ help
+ exit 0
+fi
+
+main "$1"
+
--
2.20.1
next prev parent reply other threads:[~2022-04-06 15:32 UTC|newest]
Thread overview: 9+ messages / expand[flat|nested] mbox.gz Atom feed top
2022-04-06 15:31 [RFC PATCH v1 0/8] merge DTS repo config and tools " Juraj Linkeš
2022-04-06 15:31 ` Juraj Linkeš [this message]
2022-04-06 15:31 ` [RFC PATCH v1 2/8] dts: merge DTS pyproject.toml " Juraj Linkeš
2022-04-06 15:31 ` [RFC PATCH v1 3/8] dts: merge DTS requirements.txt " Juraj Linkeš
2022-04-06 15:31 ` [RFC PATCH v1 4/8] dts: merge DTS vm_images/Dockerfile " Juraj Linkeš
2022-04-06 15:31 ` [RFC PATCH v1 5/8] dts: merge DTS vm_images/README.md " Juraj Linkeš
2022-04-06 15:31 ` [RFC PATCH v1 6/8] dts: merge DTS vm_images/create_vm_image.py " Juraj Linkeš
2022-04-06 15:31 ` [RFC PATCH v1 7/8] dts: merge DTS vm_images/make_build_container.sh " Juraj Linkeš
2022-04-06 15:31 ` [RFC PATCH v1 8/8] dts: merge DTS vm_images/network-init.sh " Juraj Linkeš
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=20220406153151.2917346-2-juraj.linkes@pantheon.tech \
--to=juraj.linkes@pantheon.tech \
--cc=Honnappa.Nagarahalli@arm.com \
--cc=david.marchand@redhat.com \
--cc=dev@dpdk.org \
--cc=lijuan.tu@intel.com \
--cc=ohilyard@iol.unh.edu \
--cc=thomas@monjalon.net \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).