GV

GeezerVison

The World Wide Web, restored to 800 pixels of glory.

Home|About|Gaming cabinet|Archives|How it works|Starter sites

On this site

  • Sign in
  • ActionsCI/CD and automation
  • CodespacesCloud development environments
  • All Features
  • Documentation
  • Training
  • Certifications
  • Build with Copilot
  • Customize Copilot
  • Integrations
  • Trending repos
  • GitHub Sponsors
  • Developer articles
  • Enterprises

This view

  • Original page
  • New address

GeezerVison is showing github.com — GitHub - function-artisans/format-code at simple-cli

BranchesTags
Open more actions menu
 
 

Latest commit

 

History

19 Commits
19 Commits

Folders and files

NameName
Last commit message
Last commit date
.github/workflows
.github/workflows
 
 
src
src
 
 
.eslintrc.json
.eslintrc.json
 
 
.gitignore
.gitignore
 
 
.prettierrc
.prettierrc
 
 
CHANGELOG.md
CHANGELOG.md
 
 
README.md
README.md
 
 
eslint.config.mjs
eslint.config.mjs
 
 
package-lock.json
package-lock.json
 
 
package.json
package.json
 
 
tsconfig.json
tsconfig.json
 
 

Repository files navigation

format-code

Formats source code from stdin and writes the formatted code to stdout.

Install

npm install
npm run build
npm link

Usage

format-code <language> [--print-width=100] [--sql-dialect=sql] < input

Languages: angular, css, glimmer, graphql, html, javascript, json, json5, less, lwc, markdown, mdx, scss, typescript, vue, yaml, sql, sql-output.

The sql-output language formats a SQL query and its result as two Markdown code blocks.

To format the code on the macOS clipboard, run:

pbpaste | format-code json | pbcopy

macOS shortcuts

To generate a signed shortcut for each language, run:

format-code shortcuts --sql-dialect postgresql

Each shortcut formats the code on the clipboard and copies the result back to the clipboard. The command writes the files to the current directory. To import a shortcut, open its file:

open "Format JSON.shortcut"

To see all the options, run format-code shortcuts --help.

About

A CLI tool that formats code from stdin, and makes macOS shortcuts that format the code on the clipboard

Topics

code-formatterformattingmacosprettiershortcuts-appsql-formattertools

Resources

Readme
Activity
Custom properties

Stars

3 stars

Watchers

0 watching

Forks

0 forks
Report repository

Used by

Contributors

Languages

You are visitor 01402503 — GeezerVison does not store the pages you look up.
Best viewed with Netscape Navigator 4.7 or Internet Explorer 6 at 800×600. No cookies required.