shellSettingsTab.component.pug 2.4 KB
Newer Older
1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16
h3.mb-3 Shell

.form-line
    .header
        .title Shell
        .description Default shell for new tabs

    select.form-control(
        [(ngModel)]='config.store.terminal.shell',
        (ngModelChange)='config.save()',
    )
        option(
            *ngFor='let shell of shells',
            [ngValue]='shell.id'
        ) {{shell.name}}

17 18 19 20
.alert.alert-info.d-flex.align-items-center(*ngIf='config.store.terminal.shell.startsWith("wsl")')
    .mr-auto WSL terminal only supports 16 colors until ConPTY is implemented in node-pty
    button.btn.btn-secondary((click)='openConPtyInfo()') More Information

21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47
.form-line(*ngIf='config.store.terminal.shell == "custom"')
    .header
        .title Custom shell

    input.form-control(
        type='text',
        [(ngModel)]='config.store.terminal.customShell',
        (ngModelChange)='config.save()',
    )

.form-line(*ngIf='persistenceProviders.length > 0')
    .header
        .title Session persistence
        .description Restores tabs when Terminus is restarted
    select.form-control(
        [(ngModel)]='config.store.terminal.persistence',
        (ngModelChange)='config.save()',
    )
        option([ngValue]='null') Off
        option(
            *ngFor='let provider of persistenceProviders',
            [ngValue]='provider.id'
        ) {{provider.displayName}}

.form-line
    .header
        .title Working directory
48 49 50 51 52 53 54 55 56 57
    .input-group
        input.form-control(
            type='text',
            placeholder='Home directory',
            [(ngModel)]='config.store.terminal.workingDirectory',
            (ngModelChange)='config.save()',
        )            
        .input-group-btn
            button.btn.btn-secondary((click)='pickWorkingDirectory()')
                i.fa.fa-folder-open
58 59 60 61 62 63 64 65 66 67 68 69 70 71 72 73

.form-line
    .header
        .title Environment
        .description Inject additional environment variables
        
    div
        .mb-2.d-flex.align-items-center(*ngFor='let pair of environmentVars')
            input.form-control.w-50([(ngModel)]='pair.key', (blur)='saveEnvironment()', placeholder='Variable name')
            input.form-control.w-50.mr-1([(ngModel)]='pair.value', (blur)='saveEnvironment()', placeholder='Value')
            button.btn.btn-secondary((click)='removeEnvironmentVar(pair.key)')
                i.fa.fa-trash-o
                
        button.btn.btn-secondary((click)='addEnvironmentVar()')
            i.fa.fa-plus.mr-2
            span Add