Network Security Internet Technology Development Database Servers Mobile Phone Android Software Apple Software Computer Software News IT Information

In addition to Weibo, there is also WeChat

Please pay attention

WeChat public account

Shulou

Examples of sublime text3 formatting json and formatting sql code

2025-03-29 Update From: SLTechnology News&Howtos shulou NAV: SLTechnology News&Howtos > Internet Technology >

Share

Shulou(Shulou.com)06/02 Report--

This article mainly introduces sublime text3 formatting json and formatting sql code examples, the article introduces in great detail, has a certain reference value, interested friends must read it!

1. Format json text

Step 1: use the shortcut keys View- > show console (View-> Show / hide console) or (Ctrl+ `) to open the console, copy the following code, and enter, and then restart sublime--. For more information, please see: https://packagecontrol.io/installation#st3

Import urllib.request,os,hashlib; h = '6f4c264a24d933ce70df5dedcf1dcaee' +' ebe013ee18cced0ef93d5f746d80ef60'; pf = 'Package Control.sublime-package'; ipp = sublime.installed_packages_path (); urllib.request.install_opener (urllib.request.build_opener (urllib.request.ProxyHandler (); by = urllib.request.urlopen (' http://packagecontrol.io/' + pf.replace ('','% 20'). Read (); dh = hashlib.sha256 (by). Hexdigest () Print ('Error validating download (got% s instead of% s), please try manual install'% (dh, h)) if dh! = h else open (os.path.join (ipp, pf),' wb') .write (by)

Step 2: install the pretty json plug-in

Method 1: click preferences-> Package Control- > enter install package, enter-> wait a minute, type Pretty json in the box that appears, enter enter, and then install

Method 2: shortcut key ctrl+shift+p, and then the same: enter install package, enter-> wait a minute, type Pretty json in the box that appears, enter enter, and then install

Step 3: shortcut key ctrl+alt+j to format json text

two。 Format sql code

Same as above, install the SqlBeautifier plug-in

Then: first ctrl+k, then ctrl+f for formatting

The above is all the content of the article "sublime text3 formatting json and formatting sql code". Thank you for reading! Hope to share the content to help you, more related knowledge, welcome to follow the industry information channel!

Welcome to subscribe "Shulou Technology Information " to get latest news, interesting things and hot topics in the IT industry, and controls the hottest and latest Internet news, technology news and IT industry trends.

Views: 0

*The comments in the above article only represent the author's personal views and do not represent the views and positions of this website. If you have more insights, please feel free to contribute and share.

Share To

Internet Technology

Wechat

© 2024 shulou.com SLNews company. All rights reserved.

12
Report