This file contains hidden or 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
-- listing only records that appear more than twice | |
-- in result which finds points within areas | |
-- | |
-- the partitioning allows us to figure the results | |
-- alongside corresponding dulplicate areas | |
-- | |
-- the n.type may be skipped, is included as aexample | |
select * from ( | |
select |
This file contains hidden or 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
jq -sc '.[] | .result."attendance-areas"[] | { | |
type: "Feature", | |
properties: { | |
id: .id, | |
grade: .grade | tostring, | |
openEnrollment: .openEnrollment, | |
name: .name, }, | |
geometry: .geometry, }' input/school-page-*.json > prepared/school.geojson |
This file contains hidden or 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
const saxpath = require('./lib/saxpath'); | |
const fs = require('fs'); | |
const zlib = require('zlib'); | |
const sax = require('sax'); | |
const saxParser = sax.createStream(true); | |
const deflate = zlib.createGunzip(); | |
const fileStream = fs.createReadStream('../discogs_20211101_releases.xml.gz'); | |
const streamer = new saxpath.SaXPath(saxParser, '/releases/release'); |
This file contains hidden or 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
#!/usr/local/bin/perl | |
use IO::Uncompress::Gunzip qw(gunzip $GunzipError); | |
use XML::XPath; | |
my $ifile = '/Users/user/Downloads/discogs_20211101_releases.xml.gz'; | |
my $ioref = IO::Uncompress::Gunzip->new( $ifile ) | |
or die "gunzip failed: $GunzipError\n"; | |
my $xp = XML::XPath->new(ioref => $ioref ); |
This file contains hidden or 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
#!/usr/bin/perl | |
use feature say; | |
my @a = ( | |
" asd", | |
" asd ", | |
" bsd", | |
" XXX", | |
"10000" | |
); |
This file contains hidden or 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
[string[]] $a = ( | |
" asd", | |
" asd ", | |
" bsd", | |
" XXX", | |
"10000" | |
) | |
[string] $spacer = "" |
This file contains hidden or 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
function Install-CollectDependencies { | |
Set-PackageSource -SourceName nuget.org -NewLocation https://www.nuget.org/api/v2 | |
Install-Package System.Numerics.Vectors,System.ValueTuple -SkipDependencies -Destination packages | |
Install-Package System.Runtime.CompilerServices.Unsafe -SkipDependencies -Destination packages | |
Install-Package System.Memory,System.ValueTuple -SkipDependencies -Destination packages | |
Install-Package System.Threading,System.Threading.Tasks -SkipDependencies -Destination packages | |
Install-Package Runtime.Native.System,System.Runtime.Handles,System.Runtime.InteropServices -SkipDependencies -Destination packages | |
Install-Package System.Reflection.Extensions -SkipDependencies -Destination packages | |
Install-Package System.Console,System.AppContext,System.Collections -SkipDependencies -Destination packages | |
Install-Package Microsoft.Win32.Primitives,System.Globalization.Calendars -SkipDependencies -Destination packages |
This file contains hidden or 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 GIST is available under the conditions of | |
// -- https://creativecommons.org/licenses/by/4.0/ | |
// | |
// this are four approaches to solution to one trivial task from | |
// Bulgaria's softuni's curriculum that i was asked to help with | |
// | |
// | |
// the input is basically 4 integers K, L, M, N | |
// | |
// then we have a integer ranges for the digits A, B, C, D |
This file contains hidden or 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 GIST is available under the conditions of | |
# https://creativecommons.org/licenses/by/4.0/ | |
using namespace Oracle.ManagedDataAccess.Core | |
# the following is needed if the connector is already globally installed | |
# but IS OKAY even without dependencies, as these install half gig of the .NET core libs anyway | |
# | |
# $dest = "$(gl)\packages\" | |
# Install-Package -Name Oracle.ManagedDataAccess.Core -Destination $dest -SkipDependencies |