New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

SQL Syntax in strings #536

Open
klaidliadon opened this Issue May 27, 2014 · 0 comments

Comments

Projects
None yet
1 participant
@klaidliadon

klaidliadon commented May 27, 2014

By adding this:

<dict>
    <key>begin</key>
    <string>``(?i)(?=\s*(?:SELECT|INSERT|UPDATE|DELETE|CREATE|REPLACE|ALTER)\b)</string>
    <key>beginCaptures</key>
    <dict>
        <key>0</key>
        <dict>
            <key>name</key>
            <string>punctuation.definition.string.begin.go</string>
        </dict>
    </dict>
    <key>end</key>
    <string>``</string>
    <key>endCaptures</key>
    <dict>
        <key>0</key>
        <dict>
            <key>name</key>
            <string>punctuation.definition.string.end.go</string>
        </dict>
    </dict>
    <key>name</key>
    <string>string.quoted.raw.sql.go</string>
    <key>patterns</key>
    <array>
        <dict>
            <key>include</key>
            <string>source.sql</string>
        </dict>
    </array>
</dict> 

to the standard go syntax file before the normal multiline string, you can get sql syntax in strings. It will be nice have the same in GoSublime syntax

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment