Skip to content

Code format uncrustify#70

Open
nopeslide wants to merge 5 commits intoShilaTu:masterfrom
nopeslide:code_format_uncrustify
Open

Code format uncrustify#70
nopeslide wants to merge 5 commits intoShilaTu:masterfrom
nopeslide:code_format_uncrustify

Conversation

@nopeslide
Copy link
Copy Markdown
Contributor

@nopeslide nopeslide commented Apr 26, 2020

Related Issues & PRs

Description

  • docker image for uncrustify
  • makefile target uncrustify to format code
  • makefile target check-uncrustify to see if code format is needed
  • .uncrustify.cfg config
  • CI action to check if code conforms

Context

uncrustify may be better suited than clang-format for our use-case
simply run make check-uncrustify to see what would change on format

Testing

  • make format
  • make check-format
  • need feedback

Documentation

  • needs documentation in CONTRIBUTING

@nopeslide nopeslide force-pushed the code_format_uncrustify branch from 0f0a71d to 5c20213 Compare April 26, 2020 00:11
@nopeslide nopeslide force-pushed the code_format_uncrustify branch from 5c20213 to d0cbdcc Compare April 26, 2020 08:54
@nopeslide nopeslide force-pushed the master branch 2 times, most recently from bf436ac to 7e9728e Compare April 26, 2020 15:04
@nopeslide nopeslide force-pushed the code_format_uncrustify branch from 760988f to 9d5ac5a Compare April 26, 2020 15:11
@nopeslide nopeslide force-pushed the code_format_uncrustify branch 2 times, most recently from 4b1be2c to dd551fd Compare April 27, 2020 09:21
Comment thread components/lifesensor_common/include/macro/queue.h
Comment thread components/lifesensor_common/include/macro/task.h
Comment thread components/spo2/include/spo2.h
Comment thread components/spo2/src/spo2.c
Comment thread components/spo2/src/spo2.c
Comment thread components/spo2/src/spo2.c Outdated
Comment thread components/spo2/src/spo2.c
Comment thread components/spo2/src/spo2_filter.c Outdated
Comment thread components/spo2/src/spo2_filter.c Outdated
Comment thread components/ulp_adc/src/ulp.c Outdated
Comment thread components/spo2/src/spo2.c Outdated
@nopeslide
Copy link
Copy Markdown
Contributor Author

uncrustify was updated so I updated everything

Copy link
Copy Markdown
Member

@ikstream ikstream left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

A few minor thinks, but looks good to me so far

Comment thread CONTRIBUTING.md Outdated
Comment thread components/spo2/src/spo2_filter.c Outdated
@nopeslide nopeslide force-pushed the code_format_uncrustify branch 2 times, most recently from c9d134f to 8af9a06 Compare May 5, 2020 17:01
@nopeslide nopeslide force-pushed the code_format_uncrustify branch 6 times, most recently from 2127cac to c1590ac Compare May 13, 2020 09:35
@nopeslide nopeslide force-pushed the code_format_uncrustify branch from c1590ac to 012c81f Compare May 13, 2020 09:40
Copy link
Copy Markdown
Member

@ikstream ikstream left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

lgtm so far, except for the commented types of indentions

Comment thread components/channel/include/channel.h
Comment thread components/channel/include/channel.h
Comment thread components/lifesensor_common/include/macro/queue.h
@nopeslide nopeslide marked this pull request as draft November 27, 2020 14:19
@ikstream ikstream marked this pull request as ready for review April 29, 2021 09:54
@ikstream ikstream requested a review from a team as a code owner April 29, 2021 09:54
Copy link
Copy Markdown
Member

@ikstream ikstream left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Only one nitpick left from my side. Do we need to address this, or do you think it's OK to leave it that way?

*/
#ifndef offsetof
#define offsetof(TYPE, MEMBER) ((size_t) &((TYPE *)0)->MEMBER)
# define offsetof(TYPE, MEMBER) ((size_t)&((TYPE*)0)->MEMBER)
Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

While it should work it does not look right to me

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

Linter & Auto code formatting

2 participants