Skip to content

GitLab

  • Menu
Projects Groups Snippets
    • Loading...
  • Help
    • Help
    • Support
    • Community forum
    • Submit feedback
    • Contribute to GitLab
  • Sign in
  • G gitlabhq1
  • Project information
    • Project information
    • Activity
    • Labels
    • Members
  • Repository
    • Repository
    • Files
    • Commits
    • Branches
    • Tags
    • Contributors
    • Graph
    • Compare
  • Issues 21
    • Issues 21
    • List
    • Boards
    • Service Desk
    • Milestones
  • Merge requests 12
    • Merge requests 12
  • CI/CD
    • CI/CD
    • Pipelines
    • Jobs
    • Schedules
  • Deployments
    • Deployments
    • Environments
    • Releases
  • Monitor
    • Monitor
    • Incidents
  • Packages & Registries
    • Packages & Registries
    • Package Registry
    • Infrastructure Registry
  • Analytics
    • Analytics
    • CI/CD
    • Repository
    • Value stream
  • Wiki
    • Wiki
  • Snippets
    • Snippets
  • Activity
  • Graph
  • Create a new issue
  • Jobs
  • Commits
  • Issue Boards
Collapse sidebar
  • gpt
  • large_projects
  • gitlabhq1
  • Issues
  • #7950

Closed
Open
Created Oct 03, 2014 by Administrator@rootOwner

Edit on web interface adds carriage returns to file.

Created by: cirosantilli

This only happens on master, not on gitlab.com.

To reproduce:

  • create a new repo
  • create a file locally that ends in newline: echo a. Double check it has no carriage return: hd a.
  • push to the new repo
  • clone somewhere else: hd a says the file hasn't changed as expected.
  • go to the edit blob view on the web interface
  • don't modify the file content: keep it as it.
  • enter commit message
  • commit. Surprise! Should not commit because no changes.
  • clone again somewhere else. Suprise! The file has carriage returns.

Normally, this shouldn't make the commit since the file was not changed, but it does as carriage returns were added.

This is exposed at the following test: https://github.com/gitlabhq/gitlabhq/pull/7856/files#r18390519 which I added to an untested feature.

Does anyone reproduce? If yes, I consider this is a critical bug which affects repository integrity.

This may be https://github.com/gitlabhq/gitlabhq/issues/3982 v2

Assignee
Assign to
Time tracking