(filename string, lineIndices []int)
| 156 | } |
| 157 | |
| 158 | func (p *PatchBuilder) RemoveFileLineRange(filename string, lineIndices []int) error { |
| 159 | info, err := p.getFileInfo(filename) |
| 160 | if err != nil { |
| 161 | return err |
| 162 | } |
| 163 | info.mode = PART |
| 164 | info.includedLineIndices, _ = lo.Difference(info.includedLineIndices, lineIndices) |
| 165 | if len(info.includedLineIndices) == 0 { |
| 166 | p.removeFile(info) |
| 167 | } |
| 168 | |
| 169 | return nil |
| 170 | } |
| 171 | |
| 172 | type RenderPatchForFileOpts struct { |
| 173 | Filename string |
nothing calls this directly
no test coverage detected