text
stringlengths
7
2.39k
embedding
listlengths
768
768
readFull reads from r into buf until it has read len(buf). It returns the number of bytes copied and an error if fewer bytes were read. If an EOF happens after reading fewer than len(buf) bytes, io.ErrUnexpectedEOF is returned.
[ 1.0425517559051514, -0.1684834063053131, 0.7267130613327026, -0.024673666805028915, -0.7664096355438232, -0.265116810798645, 0.570618212223053, -0.15344437956809998, 0.01092812791466713, 0.2034624069929123, -0.7318741083145142, 0.01548693235963583, 0.04944480210542679, -0.5978296399116516,...
StatusCode defines the status code required.
[ 0.6949130296707153, -1.268599271774292, 0.2852928340435028, 0.5379058122634888, -0.21996374428272247, 1.181760311126709, -0.17323164641857147, 1.5807801485061646, 0.45037391781806946, -0.06428888440132141, -0.6147391200065613, -0.06792475283145905, 0.8519008159637451, 0.10322259366512299, ...
Write writes the given slice of bytes in the internal buffer.
[ -1.898690938949585, -0.025149008259177208, 0.23984961211681366, 0.44766730070114136, 1.064102292060852, 0.49289393424987793, 0.22084909677505493, -0.10052578896284103, 0.02097693830728531, -0.2703532874584198, -1.0486359596252441, 0.12476342916488647, -1.0209304094314575, 0.277171730995178...
WriteHeader writes the HTTP response status code.
[ -0.3963841199874878, -1.2301920652389526, 0.511236846446991, 0.2979030907154083, 1.0902905464172363, 0.2543070912361145, 0.6466681361198425, 0.6223370432853699, -0.04939502850174904, -0.21976511180400848, -0.5425609946250916, -0.45966920256614685, 0.3568967580795288, -0.02516784705221653, ...
Flush flushes the cached data, if possible.
[ 0.3669518232345581, 0.6279067397117615, 0.09913668781518936, 0.6050337553024292, 0.041842568665742874, 0.4763695299625397, 0.34120726585388184, -0.5312408208847046, -0.1202172189950943, -0.8557795286178589, -0.01480106357485056, 1.488925576210022, 0.6173322796821594, 0.9919924736022949, ...
NewWriterStub creates a new WriterStub which implements a http.ResponseWriter interface.
[ -0.826077401638031, -0.06558982282876968, 0.4321083128452301, 0.16006536781787872, 0.22290536761283875, -0.7495024800300598, 1.4915894269943237, 0.09727609157562256, 0.20661361515522003, -1.5838913917541504, -0.269694060087204, -0.36762115359306335, -0.062424641102552414, -0.41875800490379...
Write writes the given slice of bytes in the internal buffer.
[ -1.898690938949585, -0.025149008259177208, 0.23984961211681366, 0.44766730070114136, 1.064102292060852, 0.49289393424987793, 0.22084909677505493, -0.10052578896284103, 0.02097693830728531, -0.2703532874584198, -1.0486359596252441, 0.12476342916488647, -1.0209304094314575, 0.277171730995178...
WriteHeader writes the HTTP response status code.
[ -0.3963841199874878, -1.2301920652389526, 0.511236846446991, 0.2979030907154083, 1.0902905464172363, 0.2543070912361145, 0.6466681361198425, 0.6223370432853699, -0.04939502850174904, -0.21976511180400848, -0.5425609946250916, -0.45966920256614685, 0.3568967580795288, -0.02516784705221653, ...
NewBufferWriter creates a new writer buffer.
[ -0.06382247060537338, -0.3410167396068573, 0.2982928454875946, 0.7428387999534607, -0.16171403229236603, -1.2681161165237427, 0.42410898208618164, -0.30754098296165466, -0.32650652527809143, -0.6794623732566833, -1.2892699241638184, -0.14454416930675507, -0.3324974477291107, 0.505370914936...
Close closes the used WriteCloser.
[ -0.4581204652786255, -1.447959065437317, 0.6078352928161621, -0.11946693062782288, -0.6919675469398499, -0.2363540381193161, 0.7418379783630371, -0.5675426125526428, -0.7000846862792969, -0.723399817943573, 1.032819151878357, -0.44474199414253235, -0.776540994644165, 1.1525200605392456, ...
Write writes the giben
[ -0.5847035646438599, -0.47764331102371216, 0.11783161014318466, 0.736730694770813, 1.7195112705230713, 1.1865233182907104, 0.13085247576236725, 0.8796911239624023, -1.1622873544692993, 0.3781340420246124, -0.34349265694618225, -0.5112563967704773, -1.497487187385559, 0.4667229652404785, ...
NopWriteCloser returns a WriteCloser with a noop Close method wrapping the provided Writer w.
[ -0.853812575340271, -0.6462075710296631, 0.4457416236400604, -0.5166560411453247, -1.107795000076294, 0.3334108293056488, 0.9599065780639648, -1.368666172027588, 0.10548489540815353, -1.2555737495422363, 1.1985046863555908, -0.8576124906539917, -0.9561788439750671, 1.1845535039901733, -1...
CopyURL provides update safe copy by avoiding shallow copying User field
[ -0.8330442309379578, -0.5407593250274658, 0.27919554710388184, 1.8009060621261597, -2.054825782775879, 1.506580114364624, 0.4870939552783966, 0.12679925560951233, 0.07699967920780182, 0.8056584000587463, 0.15471449494361877, 0.013239833526313305, 0.009566986002027988, -0.9682533740997314, ...
CopyHeaders copies http headers from source to destination, it does not overide, but adds multiple headers
[ -0.7371597290039062, -0.04847878962755203, 0.5779741406440735, 0.8386929035186768, -0.29353201389312744, 0.6179434657096863, -0.998428463935852, -0.9167797565460205, -0.034907229244709015, 0.8923682570457458, -0.3884998857975006, -0.67023766040802, 0.21868987381458282, -0.5940335392951965,...
HasHeaders determines whether any of the header names is present in the http headers
[ 0.12935923039913177, -0.45554429292678833, 0.7330812811851501, 0.4802992343902588, 0.8477293848991394, 0.006114335730671883, -1.6977285146713257, -0.1097479909658432, -0.7063636779785156, 0.44812649488449097, 0.029769031330943108, -1.0560392141342163, -0.8273602724075317, 0.524713397026062...
RemoveHeaders removes the header with the given names from the headers map
[ -1.1116827726364136, -0.7743411064147949, 0.4907270669937134, 0.0969780683517456, -0.9472125172615051, -0.2252076119184494, -1.156862497329712, -0.11085492372512817, -0.5897153615951538, 0.5549837946891785, -0.9162839651107788, -1.2494174242019653, -1.6324212551116943, -0.7064633965492249,...
IsWebsocketRequest determines if the specified HTTP request is a websocket handshake request.
[ -0.5989129543304443, 1.0906586647033691, 0.4072348475456238, 0.5898222923278809, -0.6198874711990356, -0.9935628771781921, -0.32874706387519836, -1.624711275100708, 1.6112807989120483, 0.41491493582725525, 0.5705868005752563, 1.2770895957946777, -0.005524992942810059, 0.7447492480278015, ...
ConstainsHeader checks if the given header field is present if the given HTTP request.
[ -0.2759598195552826, -0.5071071982383728, 0.3372551202774048, 1.0076463222503662, 0.4111386835575104, 1.0671031475067139, -1.1839470863342285, -0.37839242815971375, -0.4760463535785675, 0.27993252873420715, 0.4400097131729126, -0.5532438158988953, -0.7469255924224854, 0.23027567565441132, ...
init initializes the default transport
[ 0.061254046857357025, -0.2958049178123474, 0.22684544324874878, 0.3352903723716736, 1.240118384361267, 0.37847983837127686, -0.13903957605361938, 0.08990702033042908, -0.23043526709079742, -1.0052622556686401, -1.8338876962661743, 0.25885826349258423, -0.3072417676448822, 0.023957999423146...
EnsureTransporterFinalized will ensure that when the HTTP client is GCed the runtime will close the idle connections (so that they won't leak) this function was adopted from Hashicorp's gocleanhttp package.
[ -0.19846227765083313, -0.381893128156662, 0.48670703172683716, 0.044573307037353516, 0.7161096930503845, 0.45917218923568726, -0.16928742825984955, -1.0855205059051514, -0.7275221347808838, 0.6236879229545593, -0.37524935603141785, -0.5147441625595093, -0.799535870552063, 0.689966976642608...
NewDefaultTransport returns a new http.Transport with the same default values as http.DefaultTransport, but with idle connections and keepalives disabled.
[ -0.40045395493507385, -0.8609206080436707, 0.4784836173057556, 0.7608556747436523, 0.15647578239440918, 0.5235255360603333, -0.2548186779022217, -1.4449329376220703, 0.20192676782608032, -0.7199057340621948, -1.3866467475891113, -0.6462361216545105, -1.2031114101409912, -0.3834262490272522...
NewDefaultPooledTransport returns a new http.Transport with similar default values to http.DefaultTransport. Do not use this for transient transports as it can leak file descriptors over time. Only use this for transports that will be reused for the same host(s).
[ -0.008935771882534027, -0.44387614727020264, 0.3329927325248718, 0.04992121458053589, 0.08641420304775238, 0.21785736083984375, 0.2453981190919876, -1.0765618085861206, -0.17781375348567963, -0.48217839002609253, -1.4246084690093994, 0.6782506704330444, -0.2367657572031021, -0.129028245806...
Bytes transforms a number into a string with 1024 as base. Arguments: n number to transform, decimals number of decimals to show, long if true, show full names, otherwise show abbreviated.
[ 0.4718482494354248, 0.40042439103126526, 0.4484749734401703, -0.9165810942649841, -0.18842802941799164, -0.4477333724498749, -0.24361571669578552, -0.22951380908489227, 0.03855425864458084, -0.23515625298023224, -0.7914818525314331, 0.16076739132404327, 0.4691721200942993, -0.2158339768648...
Kilos transforms a number into a string with 1000 as base Arguments: n number to transform, decimals number of decimals to show, long if true, show full names, otherwise show abbreviated.
[ 0.7594971060752869, 0.5784801840782166, 0.496709406375885, -0.678546130657196, -0.8383432626724243, -0.6930052638053894, -0.4639788269996643, 0.1211540624499321, 0.058045148849487305, 0.5993110537528992, -0.47743088006973267, -0.15268771350383759, 1.0610957145690918, 0.09493651241064072, ...
human generic number to string conversion function
[ -0.7925304770469666, -0.3785226047039032, 0.19797952473163605, 0.6379854083061218, -0.10805277526378632, 0.0957992821931839, -0.3381099998950958, -0.9415032863616943, -1.466274619102478, -0.3045414686203003, -0.5325832366943359, 0.34009698033332825, 1.0484191179275513, -0.05997548252344131...
Abs returns the absolute value of x.
[ -0.7199231386184692, 0.04004938155412674, 0.2773377001285553, 0.20235779881477356, -0.5855484008789062, 0.5722395181655884, -1.5159964561462402, -0.8163765668869019, -0.03740756958723068, -1.1418683528900146, -0.26121699810028076, 1.4244658946990967, 1.1791272163391113, -0.3735523521900177...
LoginAs is function to check authorization user_is_login
[ -0.632684588432312, -0.6399173140525818, 0.6670523881912231, 1.968973994255066, -0.7235684394836426, -0.07658802717924118, -0.481946736574173, -0.06484996527433395, 1.4340662956237793, -0.22844506800174713, 0.4376547336578369, 1.2256956100463867, 1.3309277296066284, -0.5448716282844543, ...
If debugging output is enabled, prints the elapsed time between the last call to timeDelta() (or program start, if it hasn't been called before), and the current call to timeDelta().
[ 0.11891624331474304, -0.2008804976940155, 0.759268045425415, 0.10295367985963821, 0.3279491066932678, 0.3269675374031067, 1.1823214292526245, -0.4103040099143982, 0.07516956329345703, -0.08652780205011368, 0.24649161100387573, 0.4197332561016083, -0.4583786427974701, 1.342881441116333, -...
If the given path starts with a tilde, performs shell glob expansion to convert it to the path of the home directory. Otherwise returns the path unchanged.
[ 0.6024479269981384, 0.6156141757965088, 0.5895316004753113, 0.9318973422050476, -0.2599351704120636, 0.3400162160396576, 1.2315020561218262, -0.6118309497833252, 0.9331998229026794, 0.5831947922706604, 0.887116014957428, -0.42405691742897034, -0.3392995595932007, 0.1413341462612152, -0.5...
Utility function to decode hexencoded bytes; treats any encoding errors as fatal errors (we assume that checkConfigValidity has already made sure the strings in the config file are reasonable.)
[ 0.6474577188491821, -0.8097253441810608, 0.26568642258644104, 0.27085980772972107, 0.05394081398844719, 0.5674862265586853, -0.8536645770072937, 1.7843164205551147, -0.1836591362953186, 0.16473253071308136, -0.04253141209483147, -0.1275428682565689, -0.7617542743682861, 0.22431452572345734...
Returns a string that gives the given number of bytes with reasonable units. If 'fixedWidth' is true, the returned string will always be the same length, which makes it easier to line things up in columns.
[ 0.11058046668767929, 0.8333823680877686, 0.6086385846138, -1.2714345455169678, -0.9975230097770691, 0.016356822103261948, 0.027529986575245857, -0.21981880068778992, 0.7116999626159668, -0.5641792416572571, 0.04789742827415466, -0.11160295456647873, -0.290292888879776, 0.12182583659887314,...
Called to print overall statistics after an upload or download is finished.
[ 0.04261104017496109, -1.354030728340149, 0.31146439909935, 0.03888772428035736, 0.028516549617052078, 0.0637822225689888, 1.0211763381958008, -1.0856995582580566, -0.2095075100660324, -0.3988610506057739, 0.38230496644973755, 0.6282840967178345, 0.47746047377586365, 0.7592746615409851, 0...
We've gotten an http.Response (maybe) and an error (maybe) back after performing some HTTP operation; this function takes care of figuring out if the operation succeeded, refreshes OAuth2 tokens if expiration was the cause of the failure, takes care of exponential backoff for transient errors, etc. It then returns a HT...
[ -0.14817467331886292, -0.6467328667640686, 0.6911592483520508, 0.07744672149419785, -0.4840273857116699, -1.2569804191589355, -0.7218678593635559, -0.7342941164970398, 1.0842258930206299, -0.04744676500558853, 0.4867837727069855, 0.4090467393398285, 0.06230452284216881, -1.0943971872329712...
///////////////////////////////////////////////////////////////////////// Encryption/decryption Encrypt the given plaintext using the given encryption key 'key' and initialization vector 'iv'. The initialization vector should be 16 bytes (the AES blocksize), and should be randomly generated and unique for each file tha...
[ -0.15388740599155426, 0.2925633490085602, 0.966509222984314, 0.4535819888114929, 0.8269591927528381, 0.23072394728660583, 0.46836626529693604, 0.544772744178772, 0.3946548104286194, 0.508971631526947, -0.844173789024353, 0.21864347159862518, -0.9807558655738831, -0.12501998245716095, -0....
Returns an io.Reader that encrypts the byte stream from the given io.Reader using the given key and initialization vector.
[ 0.3673904538154602, -0.2634161412715912, 0.18257084488868713, 0.4872944951057434, -0.5840891599655151, -0.3395870327949524, -0.23477120697498322, -0.4517960548400879, -0.3479575514793396, 0.21554744243621826, 0.3791821599006653, 0.5661069750785828, -0.6551387906074524, -1.1888504028320312,...
Decrypt the given cyphertext using the given encryption key and initialization vector 'iv'.
[ 0.2995796203613281, 0.5903242230415344, 0.32898184657096863, 0.8548155426979065, 0.018686408177018166, 0.19417358934879303, 0.5634263753890991, 0.6445665955543518, -0.22718511521816254, 1.011857271194458, -0.9640077948570251, 0.22726041078567505, -1.00113844871521, -0.9964753985404968, -...
Return the given number of bytes of random values, using a cryptographicallystrong random number source.
[ -0.10750506073236465, 1.357029676437378, 0.2096347212791443, -0.34587809443473816, 0.15121692419052124, -0.0690360888838768, -0.2227800488471985, -0.13688257336616516, 0.40016865730285645, -0.9638587832450867, -1.4572819471359253, -0.34331798553466797, -0.2715640366077423, -0.0390614122152...
Create a new encryption key and encrypt it using the userprovided passphrase. Prints output to stdout that gives text to add to the ~/.skicka.config file to store the encryption key.
[ 0.3363015651702881, 0.024385521188378334, 0.34932053089141846, 0.7171415686607361, 0.887956976890564, 0.44890299439430237, 0.9221670627593994, 0.3105419874191284, -0.1193755567073822, 0.8919315934181213, 0.2782306671142578, -0.051963914185762405, 0.11032052338123322, 0.5701298713684082, ...
Decrypts the encrypted encryption key using values from the config file and the user's passphrase.
[ 0.38095811009407043, 0.6258692145347595, 0.3065233826637268, 0.6323589086532593, 0.6718871593475342, 0.4084332585334778, -0.0032463150564581156, 0.935214102268219, -0.6623526811599731, 0.8813818097114563, 0.24634681642055511, -0.9659622311592102, -0.22203902900218964, 0.10270586609840393, ...
///////////////////////////////////////////////////////////////////////// Google Drive utility functions Google Drive identifies each file with a unique Id string; this function returns the drive.File corresponding to a given Id, dealing with timeouts and transient errors.
[ 0.6083009243011475, -0.40758970379829407, 0.4040898084640503, -0.8613373041152954, -0.02505911886692047, -0.815468430519104, -0.028471611440181732, -0.3817760646343231, -0.2434409260749817, -0.15963108837604523, 0.5618596076965332, -0.004261261783540249, -0.8897541761398315, 0.040382090955...
Execute the given query with the Google Drive API, returning an array of files that match the query's conditions. Handles transient HTTP errors and the like.
[ -1.203101396560669, -0.7799348831176758, 0.3395712971687317, 0.3793796896934509, 0.13344253599643707, -0.41371220350265503, -0.6346270442008972, -0.5155096650123596, -0.29394641518592834, 0.030454270541667938, 1.0041146278381348, -0.28193017840385437, -1.100096344947815, 0.0409694984555244...
Sometimes when we get a 403 error from Files.Insert().Do(), a file is actually created. Delete the file to be sure we don't have duplicate files with the same name.
[ 1.1300972700119019, 0.6501443386077881, 0.7776407599449158, 0.36127644777297974, 0.6874518990516663, -0.1712389588356018, 1.0985294580459595, 0.121604785323143, -0.26922252774238586, 0.4215773046016693, 0.5559539198875427, -0.623902440071106, -0.5527005791664124, -0.05442344397306442, -0...
If we didn't shut down cleanly before, there may be files that don't have the various properties we expect. Check for that now and patch things up as needed.
[ 0.12797850370407104, -0.7074412107467651, 0.4882339537143707, 0.33716461062431335, 0.6709915995597839, 0.06882458180189133, 0.1876046061515808, 0.5215399861335754, -0.2190340906381607, -0.6246925592422485, 1.3184683322906494, -0.2587389349937439, -0.2254006415605545, 0.8584029674530029, ...
Given an initialized drive.File structure, create an actual file in Google Drive. The returned a drive.File represents the file in Drive.
[ -0.1789337694644928, -0.7280538082122803, 0.25362882018089294, -0.354950487613678, 0.7296224236488342, 0.5541042685508728, 0.3518538773059845, -0.37435901165008545, -0.5716175436973572, -1.0253005027770996, 0.460062712430954, -0.5605683326721191, -0.6808493733406067, 0.4661271870136261, ...
Create a new drive.File with the given name inside the folder represented by parentFolder.
[ 0.8905812501907349, 0.06715033948421478, 0.38207143545150757, 0.22078455984592438, -0.2612474858760834, 1.0876535177230835, -0.15329599380493164, -0.34539127349853516, -1.883906364440918, -0.8662834167480469, 0.4301886260509491, -0.8164183497428894, -1.2342050075531006, 0.19594086706638336...
Create a drive.File for the folder with the given title and parent folder.
[ 0.47184765338897705, -0.29996177554130554, 0.3919338285923004, 0.4411037564277649, 0.14780759811401367, 0.5576375126838684, -0.7500380277633667, 0.12184550613164902, -1.762826919555664, -0.9413062334060669, 1.2438931465148926, -0.0008469242602586746, -0.46191591024398804, -0.29678493738174...
Returns the drive.File corresponding to a given path starting from the root of the Google Drive filesystem. (Note that drive.File is used to represent both files and folders in Google Drive.)
[ 0.6602734923362732, -0.41550374031066895, 0.24683766067028046, 0.19648654758930206, 0.08609110862016678, 0.10948948562145233, 0.30258312821388245, -0.9865637421607971, -0.3242110013961792, -1.2974578142166138, 0.8304038643836975, 0.6477067470550537, -0.19090436398983002, 0.2084002345800399...
Add all of the the drive.Files in 'parentFolder' to the provided map from pathnames to driveFiles. Assumes that 'path' is the path down to 'parentFolder' when constructing pathnames of files. If 'recursive' is true, also includes all files in the full hierarchy under the given folder. Otherwise, only the files directly...
[ 0.5355852842330933, 0.7019291520118713, 0.7174841165542603, 0.8815104365348816, 0.05399174615740776, -0.2949778437614441, -0.14721539616584778, 0.5064175724983215, -0.6375550627708435, -0.07927151024341583, 0.561712384223938, -0.31837159395217896, -1.4430451393127441, 0.6016687750816345, ...
Returns a map from strings to drive.Files that represents all existing files in Google Drive at the folder identified by 'path'. If 'recursive' is true, directories under the given path are processed recursively. 'includeBase' indicates whether the drive.File for the given path should be included in the result, and 'mu...
[ 0.10049165785312653, 0.08128160983324051, 0.8530411124229431, -0.21439731121063232, -0.3332096040248871, -0.20353209972381592, 0.3323290944099426, 0.25608816742897034, -0.33816322684288025, 0.2718236446380615, 0.044558651745319366, -0.017700212076306343, -0.8121574521064758, 0.540564298629...
Google Drive files can have properties associated with them, which are basically maps from strings to strings. Given a Google Drive file and a property name, this function returns the property value, if the named property is present.
[ 0.38315466046333313, -1.8150776624679565, 0.4635685384273529, -0.23893509805202484, -0.24634718894958496, 0.12007566541433334, -1.031673550605774, -0.21494099497795105, -1.050173044204712, 0.12297303229570389, 1.5619038343429565, 0.1437659114599228, -1.152303695678711, -0.49169921875, 0....
Returns the initialization vector (for encryption) for the given file. We store the initialization vector as a hexencoded property in the file so that we don't need to download the file's contents to find the IV.
[ -0.482116162776947, -0.6697129607200623, 0.5816474556922913, -0.5302766561508179, -0.15089581906795502, 0.3021920621395111, 0.09370490908622742, 0.5325096249580383, -0.18465624749660492, -0.18201760947704315, -0.9837555289268494, -0.23216639459133148, 0.0894724652171135, 0.2449857890605926...
Upload the file contents given by the io.Reader to the given drive.File.
[ -0.4920465648174286, -0.5467804670333862, 0.3835904896259308, -1.0348199605941772, 0.3455575406551361, -0.06445145606994629, -0.10404467582702637, -0.27256467938423157, -1.6034685373306274, 0.032486312091350555, 0.7122293710708618, -0.4018946886062622, -0.3518686890602112, -0.1790140420198...
Get the contents of the drive.File as an io.ReadCloser.
[ -0.0869860053062439, -1.419085144996643, 0.6962065100669861, -0.47813981771469116, -0.588342547416687, -0.012173342518508434, -0.5852823853492737, -0.8799666166305542, -1.5212079286575317, -1.084279179573059, 1.6379389762878418, -0.4425029754638672, -0.006576579995453358, 0.291932553052902...
There are a number of cases where the Google Drive API returns an error code but where it's possible to recover from the error; examples include 401 errors when the OAuth2 token expires after an hour, or 403/500 errors when we make too many API calls too quickly and we get a rate limit error. This function takes an err...
[ -0.3337416350841522, -0.4538614749908447, 0.5561740398406982, 0.052656423300504684, 0.062486667186021805, -0.848564863204956, -0.515165388584137, -0.18582433462142944, 0.3843199908733368, -0.16145683825016022, 0.7553671002388, -0.1733756810426712, -0.8469080924987793, -0.5698304176330566, ...
Perform fairly inexpensive comparisons of the file size and last modification time metadata of the local file and the corresponding file on Google Drive. If these values match, we assume that the two files are consistent and don't examine the local file contents further to see if an upload is required (unless the ignor...
[ 0.45444735884666443, -0.27159854769706726, 0.7549019455909729, -0.7095167636871338, 0.39163368940353394, 0.43896859884262085, -0.038115035742521286, -0.0863238126039505, -0.587710976600647, 0.5592117309570312, 0.7096876502037048, 0.2766503691673279, 0.0679887905716896, 1.0576505661010742, ...
Return the md5 hash of the file at the given path in the form of a string. If encryption is enabled, use the encrypted file contents when computing the hash.
[ 0.41117700934410095, -0.15967588126659393, 0.3766655921936035, 0.232992023229599, -1.2087074518203735, 0.20941315591335297, 0.7107726335525513, -0.9407581090927124, -0.5911873579025269, 0.6154999732971191, 0.3957381844520569, -0.37309780716896057, -0.35140687227249146, -0.7565658688545227,...
Returns an io.ReadCloser for given file, such that the bytes read are ready for upload: specifically, if encryption is enabled, the contents are encrypted with the given key and the initialization vector is prepended to the returned bytes. Otherwise, the contents of the file are returned directly.
[ -0.4023917019367218, -0.2912760078907013, 0.6183484792709351, -0.12685130536556244, -0.7744115591049194, 0.11690736562013626, -0.5592382550239563, -0.6870593428611755, -0.8288907408714294, 0.25748878717422485, 0.741707980632782, -0.30732235312461853, -0.42979684472084045, 0.420406937599182...
Given a file on the local disk, synchronize it with Google Drive: if the corresponding file doesn't exist on Drive, it's created; if it exists but has different contents, the contents are updated. The Unix permissions and file modification time on Drive are also updated appropriately. Besides being sent up to Google Dr...
[ -0.13125719130039215, -0.27351123094558716, 0.5646470785140991, -0.13394233584403992, 0.42966488003730774, -0.10188710689544678, 0.5126118063926697, -0.03018137440085411, -0.09392775595188141, -0.05473572760820389, -0.6677154302597046, -0.3620529770851135, 0.37562140822410583, 0.5193811058...
Synchronize a local directory hierarchy with Google Drive. localPath is the file or directory to start with, driveRoot is the directory into which the file/directory will be sent
[ 0.46600764989852905, -0.43153607845306396, 0.39626550674438477, 0.7454763054847717, 0.31032490730285645, -0.6098632216453552, 0.053596656769514084, 0.3390348255634308, 0.3376030921936035, -0.3531816005706787, 0.26786816120147705, 0.7316429018974304, -1.134156584739685, 0.47905588150024414,...
///////////////////////////////////////////////////////////////////////// Downloading files and directory hierarchies from Google Drive If a file is encrypted, it should both have the initialization vector used to encrypt it stored as a Drive file property and have encryptionSuffix at the end of its filename. This func...
[ -0.34756603837013245, -0.7779759764671326, 0.7520453929901123, 0.1881822943687439, 0.20711177587509155, 0.7650068402290344, 0.9119136929512024, 0.3946642577648163, -0.8095667362213135, 0.3595753312110901, -0.5367463231086731, 0.37424418330192566, -1.0364646911621094, 0.5179333090782166, ...
Checks to see if it's necessary to download the given drive.File in order to create or update the corresponding local file.
[ -0.4320819675922394, -0.4202350378036499, 0.6588356494903564, -0.345322847366333, 0.29633206129074097, 0.49370118975639343, 0.08234383910894394, -0.26104873418807983, -0.43580615520477295, -0.33890625834465027, 0.6401188373565674, -0.25429069995880127, 0.0023010694421827793, 1.527892589569...
Create (or update the permissions) of the local directory corresponding to the given drive folder.
[ -0.2878854274749756, -0.19962739944458008, 0.4167039394378662, -0.36104825139045715, -0.033951930701732635, -0.2958728075027466, 0.4275977611541748, 0.9237600564956665, 0.005970374681055546, -0.013618189841508865, 0.42932239174842834, 0.07855770736932755, -0.683979868888855, 0.338850885629...
Sync the given file from Google Drive to the local filesystem.
[ 0.4694593548774719, -0.7461603879928589, 0.23389796912670135, -0.18656592071056366, 0.267063707113266, 0.6046674251556396, 0.0912947729229927, -0.4811638593673706, -0.7353795170783997, 0.031137607991695404, -0.13147512078285217, 0.9229575991630554, 0.5931732654571533, 0.23012281954288483, ...
Download the full hierarchy of files from Google Drive starting at 'drivePath', recreating it at 'localPath'.
[ 0.6742634177207947, -0.4866374731063843, 0.29848334193229675, 0.7008634209632874, 0.6554538607597351, 0.03598408028483391, 0.11384076625108719, 0.2985002398490906, -0.28566306829452515, 0.02209753356873989, 0.007699563167989254, 0.7810553312301636, -0.7898914217948914, -0.16796252131462097...
///////////////////////////////////////////////////////////////////////// main (and its helpers) Create an empty configuration file for the user to use as a startingpoint.
[ 1.1763204336166382, -0.7298409938812256, 0.8301048278808594, 1.0364104509353638, 0.24786175787448883, 0.6921569108963013, 1.2766796350479126, 0.11590845882892609, -1.175345540046692, 0.3829672038555145, -0.1816665083169937, -0.58258056640625, 0.21761949360370636, 0.12171486765146255, 0.3...
Check that the configuration read from the config file isn't obviously missing needed entries so that we can give better error messages at startup while folks are first getting things setup.
[ 0.25492063164711, -0.6108013391494751, 0.2752423882484436, -0.21541829407215118, 0.5947203636169434, 0.7921138405799866, 0.7242485880851746, 0.2179960161447525, -0.7645283937454224, 0.35416868329048157, 0.31380176544189453, -0.17759566009044647, 0.4948229193687439, 1.3279061317443848, 1....
NewAPI creates a new API based on the configuration
[ -0.7406333684921265, -1.3025814294815063, 0.05434257537126541, 1.4168084859848022, -0.5296686291694641, 0.20007431507110596, -0.3305426836013794, 0.32222944498062134, -0.6407960057258606, 0.17700199782848358, -0.32571426033973694, -1.0489379167556763, -0.210251122713089, -0.041007358580827...
AddRouteV1 adds a new route to the v1 API
[ -0.7080506682395935, -0.18090589344501495, 0.6374307870864868, 0.5374848246574402, 1.0600709915161133, 0.22137267887592316, -1.2493635416030884, 0.629235565662384, -0.08031179010868073, 0.48878201842308044, -0.1461581438779831, 0.9824584722518921, -0.8153161406517029, -0.11574773490428925,...
AddRouteV1WithBasicAuth adds a new route to the v1 API that requires basic auth
[ -0.4809759557247162, -0.6160479187965393, 0.6107038259506226, 1.1747163534164429, 0.5722804069519043, 0.4971015751361847, -1.280601143836975, -0.19938938319683075, 0.00476372754201293, 0.27456220984458923, -0.35110950469970703, 0.7129674553871155, -0.2368844598531723, -0.4168819785118103, ...
Serve starts the stargate API
[ 0.08695637434720993, -0.768593966960907, 0.04550836607813835, 0.2726322114467621, -0.26495906710624695, 0.19316129386425018, -0.15266455709934235, 1.0120320320129395, -0.8485546112060547, 0.27052736282348633, -0.24538743495941162, 1.3398469686508179, -0.7692499160766602, 0.6465664505958557...
NewCmdAddApp creates a command object for the "create" command
[ -0.039732664823532104, -1.0814018249511719, 0.31416571140289307, 0.41961321234703064, 0.5559846758842468, 1.019386887550354, -0.13643936812877655, -0.8148474097251892, 0.13693198561668396, -0.7762455344200134, 0.029699549078941345, 0.29019904136657715, 0.35638898611068726, 0.98643410205841...
Run implements this command
[ -0.8637921810150146, -0.92302405834198, 0.18762052059173584, 0.052748993039131165, 0.1078813299536705, 1.3137452602386475, 1.274657964706421, 0.17377012968063354, -0.18253663182258606, -0.865464985370636, -0.723180890083313, -0.1698412299156189, -0.3265819549560547, 0.456277996301651, -0...
Get the device profiles that are currently using the command
[ -0.31424400210380554, -0.008881432004272938, 0.6284249424934387, 1.138788104057312, 1.4268149137496948, -0.44863125681877136, 0.2777445912361145, -1.035785436630249, -0.49024254083633423, 0.47613006830215454, -0.26260900497436523, 0.3410660922527313, -0.6069141030311584, 0.2226111888885498...
NewPostStorage returns an in memory socialnet.PostStorage.
[ 0.7673019170761108, -0.36488252878189087, 0.24967166781425476, 0.922297477722168, -1.0429792404174805, -0.42416617274284363, -0.6191972494125366, -0.8224461078643799, 0.17151319980621338, -0.8689870834350586, -0.6533163189888, -1.4689698219299316, -0.48098957538604736, 0.1528693288564682, ...
Create adds a Post to the in memory array in PostStorage.
[ 0.42654138803482056, 0.18824881315231323, 0.3210592269897461, 0.7214959263801575, 0.655099630355835, 0.48127448558807373, -0.8750658631324768, -0.8065292239189148, -0.22664490342140198, -0.5627826452255249, -0.8421932458877563, -0.592237114906311, -0.7112962603569031, 0.3755035996437073, ...
Read retrieves a Post from the in memory array in PostStorage.
[ 0.7942374348640442, -0.6611247062683105, 0.4696916937828064, 0.663102388381958, -0.40433910489082336, -0.39612600207328796, -0.723922073841095, -1.0693362951278687, 0.13621877133846283, -0.8662945628166199, 0.7351753115653992, 0.01157794427126646, -0.5529630184173584, -1.0122790336608887, ...
Update replaces a Post from the in memory array in PostStorage.
[ 0.7094026803970337, -0.414629727602005, 0.2917380928993225, 0.22221358120441437, -0.6216484308242798, -0.1324247568845749, -0.6906319260597229, 0.11877114325761795, 0.3282562792301178, -0.042382072657346725, -0.6788219809532166, 0.11003026366233826, -0.8114688396453857, -0.3178569376468658...
Delete removes a Post from the in memory array in PostStorage.
[ 1.441674828529358, -0.06910639256238937, 0.21067273616790771, 0.708670437335968, 0.02727808617055416, -0.07732608169317245, -0.6713886857032776, -0.09148291498422623, 0.47833478450775146, 0.1191139966249466, -0.3037196099758148, -0.1377021223306656, -0.7814406752586365, -0.1514695584774017...
List retrieves a user's posts from the in memory array in PostStorage.
[ 0.5435661673545837, -0.16094692051410675, 0.2505761981010437, 1.0149171352386475, -0.1894146203994751, -0.5964370369911194, -0.6196907758712769, -0.4227159321308136, 0.4674801826477051, -0.46908923983573914, -0.5569057464599609, -0.10526391863822937, -0.2603818476200104, -0.369187563657760...
NewRoundRobin returns Round Robin implementation(roundRobin).
[ -0.20239071547985077, -1.6758164167404175, 0.23745843768119812, -0.007589880842715502, -0.40379247069358826, -0.018037328496575356, 0.8459669947624207, -1.1213349103927612, 0.0985315591096878, -0.12305956333875656, -0.3466598689556122, 0.7657625079154968, -0.6762340664863586, 0.47586348652...
getZero returns zero value of T.
[ 0.20745079219341278, -0.7140470147132874, 0.11609986424446106, 0.8036078214645386, 0.9414696097373962, 0.20646941661834717, 0.2934268116950989, 0.14991207420825958, -1.05996835231781, 0.005735897459089756, -1.0937572717666626, 0.02337883599102497, 0.2565407156944275, 0.0748307853937149, ...
OnXxxXxxx functions are called from dispatcher client and there is only one dispatcher client, so there is no concurrency problem in these functions CreateString: create a string with specified name
[ 0.48332467675209045, 0.30313464999198914, 0.6685702204704285, 0.14871114492416382, -0.6644444465637207, 0.6375603675842285, -0.20470042526721954, -1.105470895767212, -0.33259081840515137, -0.10934414714574814, -0.49498239159584045, -0.5122972726821899, -0.42149123549461365, 0.2021339386701...
Create a String with specified name on the local vacuum server
[ -0.04498607665300369, -0.7569952011108398, 0.11404158920049667, -0.051900025457143784, -0.4208761751651764, 0.7954675555229187, -1.6555179357528687, -0.7396985292434692, 0.054320238530635834, 0.0849083662033081, -0.9108065962791443, 0.3110303282737732, -0.7374934554100037, -0.0171501748263...
OnCreateString: called when dispatcher sends create string resp
[ 0.39838647842407227, -0.7393624186515808, 0.09828381985425949, -0.2035832405090332, -0.16915763914585114, 0.1289873719215393, -0.09779194742441177, -1.2716423273086548, 0.02573527581989765, -0.3896375894546509, -0.44484344124794006, -1.1273566484451294, 0.9278611540794373, 0.05869423225522...
TODO: consider using dispatcher for service maintaince DeclareService: declare that the specified String provides specified service
[ 0.5459292531013489, -0.9106220006942749, 0.528691828250885, 0.3043004274368286, 0.3851289749145508, 0.6125689744949341, -0.3997933268547058, -0.2514924705028534, 0.838918149471283, -0.7685937881469727, 0.6702284812927246, 0.630272388458252, -0.8962113261222839, 1.1828885078430176, -0.984...
Called after string quit its routine
[ 0.8062680959701538, -1.8367128372192383, 0.03318573161959648, -0.6706998348236084, -1.1969428062438965, 0.3828265070915222, 0.9579763412475586, -1.3949551582336426, -0.08010387420654297, -0.358818382024765, -0.47602027654647827, 0.36511194705963135, -0.663146436214447, -1.1827476024627686,...
string del notification from dispatcher
[ 1.0607271194458008, -0.004026070237159729, 0.28570112586021423, 0.36286044120788574, -1.136002540588379, -0.19866734743118286, -0.41527044773101807, 0.3263290524482727, 0.30290305614471436, -0.06508480757474899, -1.1152392625808716, -0.3621536195278168, 1.2154994010925293, 0.07650482654571...
ShowDep returns info about mymodule version and it's dependencies
[ -0.16857369244098663, -1.200737476348877, 0.6178293824195862, -0.21383894979953766, -1.082119107246399, 0.7179805040359497, -0.08037546277046204, 0.25123080611228943, 0.06435415148735046, 0.09244849532842636, -1.3779047727584839, 0.28418469429016113, 0.4197414219379425, 0.8385543823242188,...
FindMatches returns a list of Pi matches. A match is defined as >= 2 entries sharing the same pi value, but different user IDs. The returned list is nil if no matches were found.
[ -0.28766223788261414, -0.02054261788725853, 0.2564864456653595, 1.1628491878509521, 0.47901099920272827, 0.3204992711544037, 0.0022438792511820793, -0.44678443670272827, -0.11666029691696167, 0.02447614260017872, -0.6962867975234985, -1.1818925142288208, -1.3268707990646362, 0.276009768247...
Handle executing the request and returning a response
[ -1.162717580795288, -0.9112850427627563, 0.5601259469985962, 0.8340012431144714, 1.137108564376831, -0.16320031881332397, -0.24824300408363342, -0.7483547925949097, 0.02878236025571823, -0.420215368270874, 0.22366876900196075, -1.888679027557373, -0.9265660047531128, -0.8318310976028442, ...
NewScanProducts creates a new http.Handler for the scan products operation
[ -0.3054591417312622, -0.5408737063407898, 0.1319003701210022, 2.0247342586517334, -1.3709628582000732, -0.08986994624137878, 0.08818019181489944, -0.7968008518218994, 0.25053077936172485, -0.41242021322250366, -0.9205588102340698, -0.297660768032074, 0.29613274335861206, -0.248864710330963...
Validate validates this scan products body
[ -0.6439176797866821, 0.0526103600859642, 0.14782162010669708, 1.2887710332870483, 0.2758539915084839, 0.655886709690094, -0.6980501413345337, -1.408792495727539, 1.2816855907440186, -0.4167933166027069, -0.06963159143924713, -0.0855424776673317, -0.6895606517791748, 0.27262747287750244, ...
ContextValidate validates this scan products body based on context it is used
[ -0.7738548517227173, -0.31230512261390686, 0.37194323539733887, 1.3268965482711792, -0.05608268454670906, 1.1180628538131714, -0.6663818955421448, -1.4667867422103882, 1.6673132181167603, 0.1659156233072281, 0.2436070591211319, 0.6696708798408508, -1.1436195373535156, 0.15637417137622833, ...
Init sets up all the workders, reads in the host data and returns the results channel or an error
[ -0.17028003931045532, 0.4469314217567444, 0.25010785460472107, 0.15893661975860596, 0.6858433485031128, 0.08760543912649155, -0.12826740741729736, -0.6283197999000549, -1.3838701248168945, -0.7339035868644714, 0.7638359069824219, 0.24351519346237183, -1.4377501010894775, 0.5659952759742737...
NewWebAnalyzer returns an analyzer struct for an ongoing job, which may be "fed" jobs via a method and returns them via a channel when complete.
[ 0.31560543179512024, -0.7473114132881165, 0.3888683319091797, 0.3771125376224518, -1.7017158269882202, -1.0264829397201538, 0.5610160827636719, -0.8166512250900269, -0.22703392803668976, -1.0040454864501953, -0.5261917114257812, 0.9736608862876892, -0.5248597264289856, 1.2898008823394775, ...
start n worker and let them listen on channel c for hosts to scan
[ 0.17957870662212372, 0.19234095513820648, 0.22384795546531677, 0.3400086760520935, 0.5701133012771606, 0.5683881640434265, 0.004683362785726786, -0.2081686109304428, -0.7818211317062378, -0.7204359769821167, -1.302951693534851, -0.012683187611401081, -0.24876542389392853, 0.28043332695961,...
worker loops until channel is closed. processes a single host at once
[ -0.5765762329101562, -0.5089367628097534, 0.5819740891456604, -0.39147406816482544, 0.5920077562332153, 0.7966687679290771, -0.014424389228224754, -0.388199120759964, -0.7952609062194824, -0.7320573329925537, -0.007122044451534748, 0.5741189122200012, -1.4816133975982666, -0.25667881965637...
do http request and analyze response
[ -1.0805697441101074, -0.7546626329421997, 0.2539963126182556, 0.9677237868309021, 1.2238281965255737, -0.038351308554410934, -0.4324166774749756, -0.9463066458702087, 0.3252372741699219, -0.6571717858314514, -0.2909419536590576, -0.4019620418548584, 0.4606962203979492, -0.21739397943019867...
runs a list of regexes on content
[ -0.3781370520591736, -0.4739775061607361, 0.20612025260925293, 0.8416613340377808, 0.8514097929000854, -0.20861241221427917, -0.1300162523984909, 0.9519541263580322, -0.6124210357666016, -0.36464619636535645, -0.2161765694618225, -0.5669097900390625, -0.9923579096794128, 0.8951500654220581...
parses a version against matches
[ -0.29873204231262207, -1.3832707405090332, 0.4188699424266815, 0.2607881426811218, -0.0868387445807457, -0.3669181764125824, 0.029529204592108727, 0.7983789443969727, -0.8130967617034912, 0.38146913051605225, -0.4841005504131317, -1.4437873363494873, -0.5677229762077332, -1.091597199440002...