TinyCodeCounter
Character counter that helps you keep track of how close you are to 280 characters and allows you to easily remove whitespace when writing tiny code to be posted on Twitter!
Details
Installs
- Total 279
- Win 136
- Mac 108
- Linux 35
May 21 | May 20 | May 19 | May 18 | May 17 | May 16 | May 15 | May 14 | May 13 | May 12 | May 11 | May 10 | May 9 | May 8 | May 7 | May 6 | May 5 | May 4 | May 3 | May 2 | May 1 | Apr 30 | Apr 29 | Apr 28 | Apr 27 | Apr 26 | Apr 25 | Apr 24 | Apr 23 | Apr 22 | Apr 21 | Apr 20 | Apr 19 | Apr 18 | Apr 17 | Apr 16 | Apr 15 | Apr 14 | Apr 13 | Apr 12 | Apr 11 | Apr 10 | Apr 9 | Apr 8 | Apr 7 | |
---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|
Windows | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 1 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 |
Mac | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 1 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 |
Linux | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 1 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 |
Readme
- Source
- raw.githubusercontent.com
TinyCodeCounter
TinyCodeCounter is a Sublime Text plugin to show character count, show how close you are to 280 characters, and easily remove whitespace when writing tiny code to be posted on Twitter under #tinycode, #p5t, #つぶやきProcessing, etc.
Installation
Via Package Control (Recommended)
If you have Package Control installed, you can install TinyCodeCounter as follows:
- Open the command palette:
cmd + shift + p
on Mac andctrl + shift + p
on Windows/Linux. - Search
Package Control: Install Package
and pressenter
. - Search
TinyCodeCounter
and pressenter
.
Manually
Download and unpack, or git clone, the latest TinyCodeCounter release as TinyCodeCounter
in the Sublime Text packages directory. You can find the packages directory by navigating to Preferences > Browse Packages
in Sublime Text. On macOS or Linux, open a terminal and type:
cd /path/to/Sublime Text 3/Packages
git clone https://github.com/gkpotter/Sublime-TinyCodeCounter.git TinyCodeCounter
After installing manually, make sure to restart Sublime Text.
Usage
Character Counting
TinyCodeCounter looks for markers (by default #tinycode, #p5t, and #つぶやきProcessing) in files of specified languages (by default Javascript, Java, and Python) and counts characters in all lines preceeding and including the line containing the marker not including whitespace. The difference between the number of characters not including whitespace and the specified character limit (by default 280) is also displayed.
Removing Whitespace
Clicking on the counter will copy all of the characters preceeding and including the line containing the marker not including whitespace to the clipboard.
For example given the following code, TinyCodeCounter displays after the marker at the end:
After clicking on the counter, the following is copied to the clipboard:
F=[];p=0;draw=_=>{createCanvas(400,400);F.push([0,0,0]);F=F.slice(0,365);translate(200+40*cos(p),200+40*sin(p));rotate(p+=0.02);F.forEach(f=>text('🌸',f[1]=88*cos(t=(f[0]+=0.1))-48*cos(11*t/6),f[2]=88*sin(t)-48*sin(11*t/6)));text('💮',0,0)}//#tinycode #p5t #つぶやきProcessing
Settings
All of the settings are documented in the settings file. You can override the defaults by navigating to Preferences > Package Settings > TinyCodeCounter > Settings
in Sublime Text.