I'm trying to use 'git add -p' to commit only a part of my code. In the diff below I want to rename 'model' to 'sharedData' (thus, removing the model line and adding the sharedData-line).
@@ -58,9 +60,11 @@
</div>
`
})
export class PanelComponent implements OnInit, OnPanelAction, OnDestroy {
- @Input() data: any;
- @Input() model: any;
+ @Input() sharedData: any;
+ @Input() model: Wrapper<any>;
+ @Input() window: string;
+
@Input() map: Map.WindowMapper;
@Input() modules: any[];
I've tried adding unnecessary lines to context (adding a space) with multiple setting, but I get 'Your edited hunk does not apply.':
@@ -58,9 +60,12 @@
@@ -58,12 +60,12 @@
</div>
`
})
export class PanelComponent implements OnInit, OnPanelAction, OnDestroy {
@Input() data: any;
- @Input() model: any;
+ @Input() sharedData: any;
@Input() model: Wrapper<any>;
@Input() window: string;
@Input() map: Map.WindowMapper;
@Input() modules: any[];
Removing context lines did also not work:
@@ -58,9 +60,8 @@
</div>
`
})
export class PanelComponent implements OnInit, OnPanelAction, OnDestroy {
- @Input() model: any;
+ @Input() sharedData: any;
@Input() map: Map.WindowMapper;
@Input() modules: any[];