Being able to configure context when git diff. #4184

Open
opened 2025-11-02 05:41:38 -06:00 by GiteaMirror · 0 comments
Owner

Originally created by @marcsiq on GitHub (Oct 25, 2019).

  • Gitea version (or commit ref): 1-10rc1
  • Git version:
  • Operating system:
  • Database (use [x]):
    • PostgreSQL
    • MySQL
    • MSSQL
    • SQLite
  • Can you reproduce the bug at https://try.gitea.io:
    • Yes (provide example URL)
    • No
    • Not relevant
  • Log gist:

Description

I would like to be able to change the number of context lines that are shown in a pull request diff.

git diff has the -U<n> option which allows you to customize the number of lines to show around a change. For example, git diff -U8 ... will show 8 lines of context.

It would be very nice to be able to change this parameter in gitea config file.

Screenshots

Originally created by @marcsiq on GitHub (Oct 25, 2019). <!-- NOTE: If your issue is a security concern, please send an email to security@gitea.io instead of opening a public issue --> <!-- 1. Please speak English, this is the language all maintainers can speak and write. 2. Please ask questions or configuration/deploy problems on our Discord server (https://discord.gg/gitea) or forum (https://discourse.gitea.io). 3. Please take a moment to check that your issue doesn't already exist. 4. Please give all relevant information below for bug reports, because incomplete details will be handled as an invalid report. --> - Gitea version (or commit ref): 1-10rc1 - Git version: - Operating system: - Database (use `[x]`): - [ ] PostgreSQL - [ ] MySQL - [ ] MSSQL - [x] SQLite - Can you reproduce the bug at https://try.gitea.io: - [ ] Yes (provide example URL) - [ ] No - [x] Not relevant - Log gist: ## Description I would like to be able to change the number of context lines that are shown in a pull request diff. `git diff` has the `-U<n>` option which allows you to customize the number of lines to show around a change. For example, `git diff -U8` ... will show 8 lines of context. It would be very nice to be able to change this parameter in gitea config file. ## Screenshots <!-- **If this issue involves the Web Interface, please include a screenshot** -->
GiteaMirror added the type/proposal label 2025-11-02 05:41:39 -06:00
Sign in to join this conversation.
1 Participants
Notifications
Due Date
No due date set.
Dependencies

No dependencies set.

Reference: github-starred/gitea#4184