On 12/21/2019 11:00 AM, Gregory Nutt wrote:

Can we simplify the workflow to avoid creating so many temp branching
in the official repo:
1.User submit PR against the master
2.Run style, build and test through CI
We have no capability to test via CI at present.  We don't even have the requirements that would define test through CI
3.Review and comment PR by committer
4.Merge PR into master if all check pass
User may have to repeat step 1 to 3 several time before PR finally accept. Note 1: step 2 may be done by committer manually before the tool is ready. Note 2: we can refine how many approvement is required before PR can be merge.

That is basically what I was doing on the Bitbucket repository. But I will not try to maintain the ASF repository in this fashion.  No one should expect me to dispose of any patches or PRs.  I don't do that anymore.

I have attached a script called review.sh.  I have sent this before.  This is the script that use for doing basic stylistic review of changes.  It is very primitive since it was only intended for my personal use.  but you can see the basic things I did.  Most the things only got un-commented if nxstyle complained about something.  indent.sh was only used if the nxstyle complaints were excessive.

Greg


#!/bin/bash

FILELIST="\
boards/arm/stm32f0l0g0/nucleo-g070rb/src/stm32_bringup.c
"

make -C tools -f Makefile.host
for file in $FILELIST; do
  echo "=== $file ============================================="
  # Replace TAB characters with spaces

#  tools/detab.exe $file junk
#  mv junk $file

  # Remove whitespace at the end of lines

#  tools/rmcr.exe $file junk
#  mv junk $file

  # Convert C++ style comments to C style comments:

#  tools/convert-comments.exe $file junk
#  mv junk $file

  # Convert hexadecimal constants to lower case

#  tools/lowhex.exe $file junk
#  mv junk $file

  # Run the indent tool on the file.  This requires manual fixups
  # including removing the bogus blank line at the top of the
  # file and and putting the final */ of multi-line comments on a
  # separate line

#  tools/indent.sh $file

  # After indent.sh, fix header files with bad pre-processor indentation

#  filename=$(basename $(file))
#  extension="${filename##*.}"
#
#  if ("X$extension" == "Xh"); then
#    sed -i -e "s/#  /#/g" $file
#  fi

  # Run the nxstyle tool (repeatedly)

  tools/nxstyle.exe -m 86 $file
done

Reply via email to