Skip to content

[DNM] *: format diff #1750

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Closed
wants to merge 4 commits into from
Closed

[DNM] *: format diff #1750

wants to merge 4 commits into from

Conversation

BusyJay
Copy link
Member

@BusyJay BusyJay commented Apr 10, 2017

This pr tries to only format the changed lines rather than anything when make format.

Note that, there is a bug in rustfmt that unrelated comment will be also formatted.

mkdir -p ${HOME}/.cargo/bin && tar xzf rustfmt-${RUSTFMT_VERSION}-linux-amd64.tar.gz -C ${HOME}/.cargo/bin --strip-components=1
# cargo install --vers =0.6.0 rustfmt || exit 0
${HOME}/.cargo/bin/rustfmt:
cargo install -f rustfmt
Copy link
Contributor

Choose a reason for hiding this comment

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

do we need to use a special version?

Copy link
Member Author

Choose a reason for hiding this comment

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

Only changes are formatted, so I think it's ok to just use the latest version.

@siddontang
Copy link
Contributor

Do we need to close #1749 now? @overvenus

@tennix
Copy link
Contributor

tennix commented Apr 10, 2017

What about circle CI?

For shell script I suggest shellcheck as linter.

@siddontang
Copy link
Contributor

PTAL @overvenus @tennix

@tennix
Copy link
Contributor

tennix commented Apr 10, 2017

LGTM

@siddontang
Copy link
Contributor

PTAL @overvenus

@BusyJay BusyJay mentioned this pull request Apr 11, 2017
@siddontang siddontang changed the title *: format diff [DNM] *: format diff Apr 12, 2017
@BusyJay
Copy link
Member Author

BusyJay commented Apr 12, 2017

It seems that implementation of file lines is naive, let's close it for now and reopen when the feature becomes stable.

@BusyJay BusyJay closed this Apr 12, 2017
@siddontang siddontang deleted the busyjay/only-format-diff branch April 24, 2017 02:50
iosmanthus pushed a commit to iosmanthus/tikv that referenced this pull request Oct 17, 2024
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.

3 participants