Grammar update

This commit is contained in:
Arfon Smith
2016-02-29 07:53:48 -07:00
parent f14ae8e51b
commit 8fea8a0b47
21 changed files with 855 additions and 0 deletions

View File

@@ -0,0 +1,38 @@
<?xml version="1.0" encoding="UTF-8"?>
<!DOCTYPE plist PUBLIC "-//Apple//DTD PLIST 1.0//EN" "http://www.apple.com/DTDs/PropertyList-1.0.dtd">
<plist version="1.0">
<dict>
<key>beforeRunningCommand</key>
<string>nop</string>
<key>command</key>
<string>#!/usr/bin/env php
&lt;?php
$path = getenv('TM_DROPPED_FILE');
$path_parts = pathinfo($path);
$info = getimagesize($path);
list($width, $height) = $info;
$mime = $info['mime'];
$contents = base64_encode(file_get_contents($path));
echo "@gfx-{$path_parts['filename']}: \"data:{$mime};base64,{$contents}\";\n";
echo "@gfx-{$path_parts['filename']}-width: {$width}px;\n";
echo "@gfx-{$path_parts['filename']}-height: {$height}px;";</string>
<key>draggedFileExtensions</key>
<array>
<string>png</string>
<string>jpeg</string>
<string>jpg</string>
<string>gif</string>
</array>
<key>input</key>
<string>selection</string>
<key>name</key>
<string>Insert inline Image</string>
<key>output</key>
<string>insertAsSnippet</string>
<key>scope</key>
<string>source.css.less</string>
<key>uuid</key>
<string>7B0CA307-CC1C-4EE2-9F63-4825800ACDA7</string>
</dict>
</plist>