VSCode = Visual Studio Code 에서 사용할 수 있는 확장(Extension) 입니다.


VSCode 에서 코드를 이쁘게 변경해 주는 확장입니다.


링크 : https://marketplace.visualstudio.com/items?itemName=HookyQR.beautify




Visual Studio Code 에서 javascript, JSON, CSS, Sass 와 HTML 의 코드를 이쁘게 변경해 줍니다.


CSS 변경전


CSS 변경후


.jsbeautifyrc settingVS Code setting
eolfiles.eol
tab_sizeeditor.tabSize
indent_with_tabs (inverted)editor.insertSpaces
wrap_line_lengthhtml.format.wrapLineLength
wrap_attributeshtml.format.wrapAttributes
unformattedhtml.format.unformatted
indent_inner_htmlhtml.format.indentInnerHtml
preserve_newlineshtml.format.preserveNewLines
max_preserve_newlineshtml.format.maxPreserveNewLines
indent_handlebarshtml.format.indentHandlebars
end_with_newlinehtml.format.endWithNewline (html)
end_with_newlinefile.insertFinalNewLine (css, js)
extra_linershtml.format.extraLiners
space_after_anon_functionjavascript.format
.insertSpaceAfterFunctionKeywordForAnonymousFunctions
space_in_parenjavascript.format
.insertSpaceAfterOpeningAndBeforeClosingNonemptyParenthesis

Note that the html.format settings will ONLY be used when the document is html. javascript.format settings are included always.

Also runs html and css beautify from the same package, as determined by the file extension. The schema indicates which beautifier each of the settings pertains to.

The .jsbeautifyrc config parser accepts sub elements of htmljs and css so that different settings can be used for each of the beautifiers (like sublime allows). Note that this will cause the config file to be incorrectly structured for running js-beautify from the command line.

Settings are inherited from the base of the file. Thus:

{
  "indent_size": 4,
  "indent_char": " ",
  "css": {
    "indent_size": 2
  }
}

Will result in the indent_size being set to 4 for JavaScript and HTML, but set to 2 for CSS. All will get the same indent_char setting.

If the file is unsaved, or the type is undetermined, you'll be prompted for which beautifier to use.

You can control which file types, extensions, or specific file names should be beautified with the beautify.languagesetting.

{
  "beautify.language": {
    "js": {
      "type": ["javascript", "json"],
      "filename": [".jshintrc", ".jsbeautifyrc"]
      // "ext": ["js", "json"]
      // ^^ to set extensions to be beautified using the javascript beautifier
    },
    "css": ["css", "scss"],
    "html": ["htm", "html"]
    // ^^ providing just an array sets the VS Code file type
  }
}

Beautify on save will be enabled when "editor.formatOnSave" is true.

Beautification on particular files using the built in Format Document (which includes formatting on save) can be skipped with the beautify.ignore option. Using the Beautify file and Beautify selection will still work. For files opened from within the workspace directory, the glob patterns will match from the workspace root. For files opened from elsewhere, or when no workspace is open, the patterns will match from the system root.

Examples:

/* ignore all files named 'test.js' not in the root folder,
   all files directly in any 'spec' directory, and
   all files in any 'test' directory at any depth
*/
"beautify.ignore": ["*/test.js", "**/spec/*", "**/test/**/*"]

/* ignore all files ending in '_test.js' anywhere */
"beautify.ignore": "**/*_test.js"

Note that the glob patterns are not used to test against the containing folder. You must match the filename as well.

Embedded version of js-beautify is v1.8.4

Use the following to embed a beautify shortcut in keybindings.json. Replace with your preferred key bindings.

{
  "key": "cmd+b",
  "command": "HookyQR.beautify",
  "when": "editorFocus"
}


VSCode = Visual Studio Code 에서 사용할 수 있는 확장(Extension) 입니다.


Firebase 프로젝트 탐색 및 관리를 위한 Visual Studio Code 확장입니다.


링크 : https://marketplace.visualstudio.com/items?itemName=jsayol.firebase-explorer





'DATABASE' 카테고리의 다른 글

MySQL - MySQL 관리  (0) 2018.12.15
SQL Server (mssql) - MSSQL 연결  (0) 2018.12.14
Mongo Runner - MongoDB의 인스턴스 접속  (0) 2018.08.28
Redis console - Redis의 인스턴스 접속  (0) 2018.08.19

VSCode = Visual Studio Code 에서 사용할 수 있는 확장(Extension) 입니다.


상태바에 IP 주소를 표시하고 텍스트로 삽입할 수 있는 확장입니다.


링크 : https://marketplace.visualstudio.com/items?itemName=Compulim.vscode-ipaddress




이 Visual Studio Code 확장을 사용하면 상태바에 현재 IP 주소를 쉽게보고, IPv4, IPv6 및 여러 활성 네트워크 인터페이스의 공용 IP 주소를 포함하여 텍스트에 삽입 할 수 있습니다.




상태바에서 IP 주소를 찾을 수 있습니다. IP 주소를 클릭하면 모든 IP 주소를 반복해서 표시해 줍니다.


IP 주소를 텍스트에 삽입하려면,

  • F1 을 눌러 커맨드 팔레트 가져 오기
  • "Insert IP Address"를 입력하거나 선택하십시오.

아래의 JSON으로 키보드 단축키를 수정할 수도 있습니다.

{
  "key": "alt+shift+i",
  "command": "ipAddress.insertIPAddress",
  "when": "editorTextFocus"
}

공인 IP 주소는 OpenDNS를 통해 얻을 수 있으며 check-ip 에서 매분마다 업데이트됩니다.

쿼리 공개 IP 주소는 패킷을 인터넷으로 보내야하므로 네트워크 트래픽을 최소화 하고자합니다. 

상태바에 공용 IP 주소가 표시되지 않으면 IP 주소를 업데이트하지 않습니다. 

그리고 그것이 보여 지더라도 우리는 1 분에 1 회 이상 그것을 업데이트하지 않을 것입니다.

VSCode = Visual Studio Code 에서 사용할 수 있는 확장(Extension) 입니다.


MySQL 관리를 위한 확장입니다.


링크 : https://marketplace.visualstudio.com/items?itemName=formulahendry.vscode-mysql



  • Manage MySQL Connections (support SSL connection)
  • List MySQL Servers
  • List MySQL Databases
  • List MySQL Tables
  • List MySQL Columns
  • Run MySQL Query


  • MySQL 접속 추가하기: VSCode 탐색의 왼쪽 아래에 "MYSQL" 을 클릭하고 + 버튼을 클릭한다. 
  • host, user, password, port 와 인증파일 경로(옵션)을 입력한다.



  • MySQL 쿼리 실행하기
    • SQL 파일에서 오른쪽 클릭을 하고, Run MySQL Query 를 클릭한다.
    • 또는 단축키 Ctrl+Alt+E 사용한다.
    • 또는 F1 을 눌러서 Run MySQL Query 를 선택한다.


  • 새로운 MySQL query 만들기 또는 MySQL 접속 변경하기 (상태바에 접속된 MySQL 접속을 볼수 있다.):

    • MySQL 서버를 오른쪽 클릭하고 New Query 를 클릭한다. 
    • 또는 MySQL database 를 오른쪽 클릭하고 New Query 를 클릭한다.

VSCode = Visual Studio Code 에서 사용할 수 있는 확장(Extension) 입니다.


어디서나 Microsoft SQL Server, Azure SQL Database 와 SQL Data Warehouse 를 개발할 수 있는 확장입니다.


링크 : https://marketplace.visualstudio.com/items?itemName=ms-mssql.mssql




  • Microsoft SQL Server, Azure SQL Database 및 SQL Data Warehouse 에 연결합니다.
  • 연결 프로필 및 가장 최근에 사용한 연결을 만들고 관리합니다.
  • IntelliSense, Go to Definition, T-SQL snippets, syntax colorizations, T-SQL 오류 유효성 검사 및 GO 배치 구분 기호로 T-SQL 스크립트 작성
  • 스크립트를 실행하고 사용하기 쉬운 그리드에서 결과를 봅니다.
  • 결과를 json 또는 csv 파일 형식으로 저장하고 편집기에서 봅니다.
  • 명령 단축키 등을 포함한 사용자 정의 가능한 확장 옵션.



  • First, install Visual Studio Code then install mssql extension by pressing F1 or ctrl+shift+p to open command palette, select Install Extension and type mssql.
  • Open an existing file with a .sql file extension or open a new text file (ctrl+n) and change the language mode to SQL by pressing ctrl+k,m and select SQLmssql commands and functionalities are enabled in the SQL language mode in Visual Studio Code editor.
  • Create a new connection profile using command palette by pressing F1, type sqlman to run MS SQL: Manage Connection Profile command. Select Create. See manage connection profiles for more information about how to create and edit connection profiles in your User Settings (settings.json) file.
  • Connect to a database by pressing F1 and type sqlcon to run MS SQL: Connnect command, then select a connection profile. You can also use a shortcut (ctrl+shift+c).
  • Write T-SQL script in the editor using IntelliSense and Snippets. Type sql in the editor to list T-SQL Snippets.
  • Execute T-SQL script or selection of statements in the script by pressing F1 and type sqlex to run MS SQL: Execute Query command. You can also use a shortcut (ctrl+shift+e). See customize shortcuts to learn about change shortcut key bindings to mssql commands.
  • View the T-SQL script execution results and messages in result view.

The extension provides several commands in the Command Palette for working with .sql files:

  • MS SQL: Connect to SQL Server, Azure SQL Database or SQL Data Warehouse using connection profiles or recent connections.
    • Create Connection Profile to create a new connection profile and connect.
  • MS SQL: Disconnect from SQL Server, Azure SQL Database or SQL Data Warehouse in the editor session.
  • MS SQL: Use Database to switch the database connection to another database within the same connected server in the editor session.
  • MS SQL: Execute Query script, T-SQL statements or batches in the editor.
  • MS SQL: Cancel Query execution in progress in the editor session.
  • MS SQL: Manage Connection Profiles
    • Create a new connection profile using command palette's step-by-step UI guide.
    • Edit user settings file (settings.json) in the editor to manually create, edit or remove connection profiles.
    • Remove an existing connection profile using command palette's step-by-step UI guide.
    • Clear Recent Connection List to clear the history of recent connections.

The following Visual Studio Code settings are available for the mssql extension. These can be set in user preferences (cmd+,) or workspace settings (.vscode/settings.json). See customize options and manage connection profilesfor more details.

{
    "mssql.maxRecentConnections": 5,
    "mssql.connections":[],
    "mssql.shortcuts": {
        "event.toggleResultPane": "ctrl+alt+r",
        "event.toggleMessagePane": "ctrl+alt+y",
        "event.prevGrid": "ctrl+up",
        "event.nextGrid": "ctrl+down",
        "event.copySelection": "ctrl+c",
        "event.maximizeGrid": "",
        "event.selectAll": "",
        "event.saveAsJSON": "",
        "event.saveAsCSV": "",
        "event.saveAsExcel": ""
    },
    "mssql.messagesDefaultOpen": true,
    "mssql.logDebugInfo": false,
    "mssql.saveAsCSV.includeHeaders": true,
    "mssql.intelliSense.enableIntelliSense": true,
    "mssql.intelliSense.enableErrorChecking": true,
    "mssql.intelliSense.enableSuggestions": true,
    "mssql.intelliSense.enableQuickInfo": true,
    "mssql.intelliSense.lowerCaseSuggestions": false,
    "mssql.resultsFontFamily": "-apple-system,BlinkMacSystemFont,Segoe WPC,Segoe UI,HelveticaNeue-Light,Ubuntu,Droid Sans,sans-serif",
    "mssql.resultsFontSize": 13,
    "mssql.copyIncludeHeaders": false,
    "mssql.copyRemoveNewLine" : true,
    "mssql.splitPaneSelection": "next",
    "mssql.format.alignColumnDefinitionsInColumns": false,
    "mssql.format.datatypeCasing": "none",
    "mssql.format.keywordCasing": "none",
    "mssql.format.placeCommasBeforeNextStatement": false,
    "mssql.format.placeSelectStatementReferencesOnNewLine": false,
    "mssql.applyLocalization": false,
    "mssql.query.displayBitAsNumber": true,
    "mssql.persistQueryResultTabs": false
}


+ Recent posts