C -> D o D
D -> C
D -> t
D -> D o D
D -> t
Discover gists
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
//https://pegjs.org/online | |
start = table / trx | |
table = "table" space s:schema "." t:tablename ":" space a:action ":" d:data {return {schema:s, table:t, action:a, data:d};} | |
trx = trx_begin / trx_commit | |
trx_begin = "BEGIN" id:trx_id? {return {trx:"BEGIN", xid:id};} | |
trx_commit = "COMMIT" id:trx_id? tm:trx_tm {return {trx:"COMMIT", xid:id, time:tm};} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
IniFile | |
= first: Section (BlankLine* others: Section*) {others.unshift(first); return others; } | |
Section | |
= section: SectionHeader "\n" values: KeyValues* {return {section:values}} | |
SectionHeader | |
= "[" section_name: word "]" {return section_name} | |
KeyValues | |
= a: word "=" value: word "\n"? {var o = {}; o[a]=value; return o;} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Content = (DocType / Comment / BalancedTag / SelfClosingTag / Text)* | |
DocType = "<!doctype " doctype:[^>]* ">" { | |
return { | |
type: 'DocType', | |
content: doctype.join('') | |
}; | |
} | |
Comment = "<!--" c:(!"-->" c:. {return c})* "-->" { |
Postgres 15 is just out, and while there is a lot to love about this new release, you're in for a surprise if you try to set it up with Django following tutorials like this one.
The reason is stated in the release announcement:
Remove PUBLIC creation permission on the public schema (Noah Misch) The new default is one of the secure schema usage patterns that Section 5.9.6 has recommended...
Provided your web app doesn't access your database as a superuser (it shouldn't) and uses a dedicated user, it is not allowed to use the public schema anymore. You have to create one for this specific user, and the next section will
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
/* | |
GITHUB MARKDOWN EXTRACTOR RULES | |
https://guides.github.com/features/mastering-markdown/ | |
http://www.table-ascii.com/ | |
http://www.loc.gov/marc/specifications/specchartables.html | |
http://www.utf8-chartable.de/unicode-utf8-table.pl |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This happens on IE for both students and teachers. | |
This is logged in the browser console in ie9: | |
SCRIPT5022: [$rootScope:infdig] 10 $digest() iterations reached. Aborting! | |
Watchers fired in the last 5 iterations: [["fn: function $locationWatch() {\n var oldUrl = $browser.url();\n var currentReplace = $location.$$replace;\n\n if (!changeCounter || oldUrl != $location.absUrl()) {\n changeCounter++;\n $rootScope.$evalAsync(function() {\n if ($rootScope.$broadcast('$locationChangeStart', $location.absUrl(), oldUrl).\n defaultPrevented) {\n $location.$$parse(oldUrl);\n } else {\n $browser.url($location.absUrl(), currentReplace);\n afterLocationChange(oldUrl);\n }\n });\n }\n $location.$$replace = false;\n\n return changeCounter;\n }; newVal: 10; oldVal: 9","fn: function(context) {\n try {\n for(var i = 0, ii = length, part; i<ii; i++) {\n if (typeof (part = parts[i]) == 'function') {\n part = part(context);\n if (trustedContext) {\n part = $sce.getTrusted(trustedContext, part);\n } else {\n part = $sce.valueOf(par |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
// Generated automatically by nearley, version 2.15.1 | |
// http://github.com/Hardmath123/nearley | |
(function () { | |
function id(x) { return x[0]; } | |
var grammar = { | |
Lexer: undefined, | |
ParserRules: [ | |
{"name": "Main", "symbols": ["ifStatement"], "postprocess": id}, | |
{"name": "ifStatement$string$1", "symbols": [{"literal":"i"}, {"literal":"f"}], "postprocess": function joiner(d) {return d.join('');}}, | |
{"name": "ifStatement", "symbols": ["ifStatement$string$1", "_", {"literal":"("}, "_", "expression", "_", {"literal":")"}, "_", "Statement", "_"], "postprocess": arr => arr[4] && arr[8]}, |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#!/bin/bash | |
### steps #### | |
# Verify the system has a cuda-capable gpu | |
# Download and install the nvidia cuda toolkit and cudnn | |
# Setup environmental variables | |
# Verify the installation | |
### | |
### to verify your gpu is cuda enable check |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
{ | |
"meta": { | |
"manifest_version": 3, | |
"locale_version": "1.3", | |
"locale_name": "简体中文", | |
"locale_type": "zh_CN", | |
"locale_last_updated": "2020-08-07 18:00:00 UTC", | |
"locale_author_name": "moelody", | |
"locale_author_email": "yfsmallmoon@gmail.com", | |
"locale_source_url": "https://gist.github.com/moelody/3159316ce726fc629fae15278bbce429" |
NewerOlder