mirror of
https://github.com/Eugeny/tabby.git
synced 2025-09-24 17:16:03 +00:00
profile args editor
This commit is contained in:
@@ -14,8 +14,8 @@ export interface ResizeEvent {
|
|||||||
|
|
||||||
export interface SessionOptions {
|
export interface SessionOptions {
|
||||||
name?: string
|
name?: string
|
||||||
command?: string
|
command: string
|
||||||
args?: string[]
|
args: string[]
|
||||||
cwd?: string
|
cwd?: string
|
||||||
env?: any
|
env?: any
|
||||||
width?: number
|
width?: number
|
||||||
|
@@ -14,6 +14,24 @@
|
|||||||
[(ngModel)]='profile.sessionOptions.command',
|
[(ngModel)]='profile.sessionOptions.command',
|
||||||
)
|
)
|
||||||
|
|
||||||
|
.form-group
|
||||||
|
label Arguments
|
||||||
|
.input-group(
|
||||||
|
*ngFor='let arg of profile.sessionOptions.args; index as i',
|
||||||
|
)
|
||||||
|
input.form-control(
|
||||||
|
type='text',
|
||||||
|
[(ngModel)]='profile.sessionOptions.args[i]',
|
||||||
|
)
|
||||||
|
.input-group-btn
|
||||||
|
button.btn.btn-secondary((click)='profile.sessionOptions.args.splice(i, 1)')
|
||||||
|
i.fa.fa-trash-o
|
||||||
|
|
||||||
|
.mt-2
|
||||||
|
button.btn.btn-secondary((click)='profile.sessionOptions.args.push("")')
|
||||||
|
i.fa.fa-plus.mr-2
|
||||||
|
| Add
|
||||||
|
|
||||||
.form-group
|
.form-group
|
||||||
label Working directory
|
label Working directory
|
||||||
input.form-control(
|
input.form-control(
|
||||||
|
@@ -15,6 +15,7 @@ export class EditProfileModalComponent {
|
|||||||
|
|
||||||
ngOnInit () {
|
ngOnInit () {
|
||||||
this.profile.sessionOptions.env = this.profile.sessionOptions.env || {}
|
this.profile.sessionOptions.env = this.profile.sessionOptions.env || {}
|
||||||
|
this.profile.sessionOptions.args = this.profile.sessionOptions.args || []
|
||||||
}
|
}
|
||||||
|
|
||||||
save () {
|
save () {
|
||||||
|
@@ -1,5 +1,8 @@
|
|||||||
.mb-2.d-flex.align-items-center(*ngFor='let pair of vars')
|
.mb-2.d-flex.align-items-center(*ngFor='let pair of vars')
|
||||||
input.form-control.w-50([(ngModel)]='pair.key', (blur)='emitUpdate()', placeholder='Variable name')
|
.input-group.w-50
|
||||||
|
input.form-control([(ngModel)]='pair.key', (blur)='emitUpdate()', placeholder='Variable name')
|
||||||
|
.input-group-append
|
||||||
|
.input-group-text =
|
||||||
input.form-control.w-50.mr-1([(ngModel)]='pair.value', (blur)='emitUpdate()', placeholder='Value')
|
input.form-control.w-50.mr-1([(ngModel)]='pair.value', (blur)='emitUpdate()', placeholder='Value')
|
||||||
button.btn.btn-secondary((click)='removeEnvironmentVar(pair.key)')
|
button.btn.btn-secondary((click)='removeEnvironmentVar(pair.key)')
|
||||||
i.fa.fa-trash-o
|
i.fa.fa-trash-o
|
||||||
|
Reference in New Issue
Block a user