123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253254255256257258259260261262263264265266267268269270271272273274275276277278279280281282283284285286287288289290291292293294295296297298299300301302303304305306307308309310311312313314315316317318319320321322323324325326327328329330331332333334335336337338339340341342343344345346347348349350351352353354355356357358359360361362363364365366367368369370371372373374375376377378379380381382383384385386387388389390391392393394395396397398399400401402403404405406407408409410411412413414415416417418419420421422423424425426427428429430431432433434435436437438439440441442443444445446447448449450451452453454455456457458459460461462463464465466467468469470471472473474475476477478479480481482483484485486487488489490491492493494495496497498499500501502503504505506507508509510511512513514515516517518519520521522523524525526527528529530531532533534535536537538539540541542543544545546547548549550551552553554555556557558559560561562563564565566567568569570571572573574575576577578579580581582583584585586587588589590591592593594595596597598599600601602603604605606607608609610611612613614615616617618619620621622623624625626627628629630631632633634635636637638639640641642643644645646647648649650651652653654655656657658659660661662663664665666667668669670671672673674675676677678679680681682683684685686687688689690691692693694695696697698699700701702703704705706707708709710711712713714715716717718719720721722723724725726727728729730731732733734735736737738739740741742743744745746747748749750751752753754755756757758759760761762763764765766767768769770771772773774775776777778779780781782783784785786787788789790791792793794795796797798799800801802803804805806807808809810811812813814815816817818819820821822823824825826827828829830831832833834835836837838839840841842843844845846847848849850851852853854855856857858859860861862863864865866867868869870871872873874875876877878879880881882883884885886887888889890891892893894895896897898899900901902903904905906907908909910911912913914915916917918919920921922923924925926927928929930931932933934935936937938939940941942943944945946947948949950951952953954955956957958959960961962963964965966967968969970971972973974975976977978979980981982983984985986987988989990991992993994995996997998999100010011002100310041005100610071008100910101011101210131014101510161017101810191020102110221023102410251026102710281029103010311032103310341035103610371038103910401041104210431044104510461047104810491050105110521053105410551056105710581059106010611062106310641065106610671068106910701071107210731074107510761077107810791080108110821083108410851086108710881089109010911092109310941095109610971098109911001101110211031104110511061107110811091110111111121113111411151116111711181119112011211122112311241125112611271128112911301131113211331134113511361137113811391140114111421143114411451146114711481149115011511152115311541155115611571158115911601161116211631164116511661167116811691170117111721173117411751176117711781179118011811182118311841185118611871188118911901191119211931194119511961197119811991200120112021203120412051206120712081209121012111212121312141215121612171218121912201221122212231224122512261227122812291230123112321233123412351236123712381239124012411242124312441245124612471248124912501251125212531254125512561257125812591260126112621263126412651266126712681269127012711272127312741275127612771278127912801281128212831284128512861287128812891290129112921293129412951296129712981299130013011302130313041305130613071308130913101311131213131314131513161317131813191320132113221323132413251326132713281329133013311332133313341335133613371338133913401341134213431344134513461347134813491350135113521353135413551356135713581359136013611362136313641365136613671368136913701371137213731374137513761377137813791380138113821383138413851386138713881389139013911392139313941395139613971398139914001401140214031404140514061407140814091410141114121413141414151416141714181419142014211422142314241425142614271428142914301431143214331434143514361437143814391440144114421443144414451446144714481449145014511452145314541455145614571458145914601461146214631464146514661467146814691470147114721473147414751476147714781479148014811482148314841485148614871488148914901491149214931494149514961497149814991500150115021503150415051506150715081509151015111512151315141515151615171518151915201521152215231524152515261527152815291530153115321533153415351536153715381539154015411542154315441545154615471548154915501551155215531554155515561557155815591560156115621563156415651566156715681569157015711572157315741575157615771578157915801581158215831584158515861587158815891590159115921593159415951596159715981599160016011602160316041605160616071608160916101611161216131614161516161617161816191620162116221623162416251626162716281629163016311632163316341635163616371638163916401641164216431644164516461647164816491650165116521653165416551656165716581659166016611662166316641665166616671668166916701671167216731674167516761677167816791680168116821683168416851686168716881689169016911692169316941695169616971698169917001701170217031704170517061707170817091710171117121713171417151716171717181719172017211722172317241725172617271728172917301731173217331734173517361737173817391740174117421743174417451746174717481749175017511752175317541755175617571758175917601761176217631764176517661767176817691770177117721773177417751776177717781779178017811782178317841785178617871788178917901791179217931794179517961797179817991800180118021803180418051806180718081809181018111812181318141815181618171818181918201821182218231824182518261827182818291830183118321833183418351836183718381839184018411842184318441845184618471848184918501851185218531854185518561857185818591860186118621863186418651866186718681869187018711872187318741875187618771878187918801881188218831884188518861887188818891890189118921893189418951896189718981899190019011902190319041905190619071908190919101911191219131914191519161917191819191920192119221923192419251926192719281929193019311932193319341935193619371938193919401941194219431944194519461947194819491950195119521953195419551956195719581959196019611962196319641965196619671968196919701971197219731974197519761977197819791980198119821983198419851986198719881989199019911992199319941995199619971998199920002001200220032004200520062007200820092010201120122013201420152016201720182019202020212022202320242025202620272028202920302031203220332034203520362037203820392040204120422043204420452046204720482049205020512052205320542055205620572058205920602061206220632064206520662067206820692070207120722073207420752076207720782079208020812082208320842085208620872088208920902091209220932094209520962097209820992100210121022103210421052106210721082109211021112112211321142115211621172118211921202121212221232124212521262127212821292130213121322133213421352136213721382139214021412142214321442145214621472148214921502151215221532154215521562157215821592160216121622163216421652166216721682169217021712172217321742175217621772178217921802181218221832184218521862187218821892190219121922193219421952196219721982199220022012202220322042205220622072208220922102211221222132214221522162217221822192220222122222223222422252226222722282229223022312232223322342235223622372238223922402241224222432244224522462247224822492250225122522253225422552256225722582259226022612262226322642265226622672268226922702271227222732274227522762277227822792280228122822283228422852286228722882289229022912292229322942295229622972298229923002301230223032304230523062307230823092310231123122313231423152316231723182319232023212322232323242325232623272328232923302331233223332334233523362337233823392340234123422343234423452346234723482349235023512352235323542355235623572358235923602361236223632364236523662367236823692370237123722373237423752376237723782379238023812382238323842385238623872388238923902391239223932394239523962397239823992400240124022403240424052406240724082409241024112412241324142415241624172418241924202421242224232424242524262427242824292430243124322433243424352436243724382439244024412442244324442445244624472448244924502451245224532454245524562457245824592460246124622463246424652466246724682469247024712472247324742475247624772478247924802481248224832484248524862487248824892490249124922493249424952496249724982499250025012502250325042505250625072508250925102511251225132514251525162517251825192520252125222523252425252526252725282529253025312532253325342535253625372538253925402541254225432544254525462547254825492550255125522553255425552556255725582559256025612562256325642565256625672568256925702571257225732574257525762577257825792580258125822583258425852586258725882589259025912592259325942595259625972598259926002601260226032604260526062607260826092610261126122613261426152616261726182619262026212622262326242625262626272628262926302631263226332634263526362637263826392640264126422643264426452646 |
- <?xml version="1.0" encoding="utf-8"?>
- <Ketarin>
- <Settings>
- <dictionary>
- <item>
- <key>
- <string>AuthorGuid</string>
- </key>
- <value>
- <string>System.String:{75a093b7-da5f-493a-b8f0-22c278f874c1}</string>
- </value>
- </item>
- <item>
- <key>
- <string>LastUpdateCheck</string>
- </key>
- <value>
- <string>AAEAAAD/////AQAAAAAAAAAEAQAAAA9TeXN0ZW0uRGF0ZVRpbWUCAAAABXRpY2tzCGRhdGVEYXRhAAAJEOGhVC47mtII4aFULjua0ogL</string>
- </value>
- </item>
- <item>
- <key>
- <string>MainForm/Size</string>
- </key>
- <value>
- <string>System.Drawing.Size:1046,476</string>
- </value>
- </item>
- <item>
- <key>
- <string>MainForm/Location</string>
- </key>
- <value>
- <string>System.Drawing.Point:203,77</string>
- </value>
- </item>
- <item>
- <key>
- <string>MainForm/WindowState</string>
- </key>
- <value>
- <string>System.Int32:0</string>
- </value>
- </item>
- <item>
- <key>
- <string>olvJobs/Application:Visibility</string>
- </key>
- <value>
- <string>System.Boolean:True</string>
- </value>
- </item>
- <item>
- <key>
- <string>olvJobs/Application:Width</string>
- </key>
- <value>
- <string>System.Int32:126</string>
- </value>
- </item>
- <item>
- <key>
- <string>olvJobs/Application:LastDisplayIndex</string>
- </key>
- <value>
- <string>System.Int32:0</string>
- </value>
- </item>
- <item>
- <key>
- <string>olvJobs/Last updated:Visibility</string>
- </key>
- <value>
- <string>System.Boolean:True</string>
- </value>
- </item>
- <item>
- <key>
- <string>olvJobs/Last updated:Width</string>
- </key>
- <value>
- <string>System.Int32:96</string>
- </value>
- </item>
- <item>
- <key>
- <string>olvJobs/Last updated:LastDisplayIndex</string>
- </key>
- <value>
- <string>System.Int32:2</string>
- </value>
- </item>
- <item>
- <key>
- <string>olvJobs/Progress:Visibility</string>
- </key>
- <value>
- <string>System.Boolean:True</string>
- </value>
- </item>
- <item>
- <key>
- <string>olvJobs/Progress:Width</string>
- </key>
- <value>
- <string>System.Int32:100</string>
- </value>
- </item>
- <item>
- <key>
- <string>olvJobs/Progress:LastDisplayIndex</string>
- </key>
- <value>
- <string>System.Int32:4</string>
- </value>
- </item>
- <item>
- <key>
- <string>olvJobs/Target:Visibility</string>
- </key>
- <value>
- <string>System.Boolean:True</string>
- </value>
- </item>
- <item>
- <key>
- <string>olvJobs/Target:Width</string>
- </key>
- <value>
- <string>System.Int32:0</string>
- </value>
- </item>
- <item>
- <key>
- <string>olvJobs/Target:LastDisplayIndex</string>
- </key>
- <value>
- <string>System.Int32:5</string>
- </value>
- </item>
- <item>
- <key>
- <string>olvJobs/Category:Visibility</string>
- </key>
- <value>
- <string>System.Boolean:True</string>
- </value>
- </item>
- <item>
- <key>
- <string>olvJobs/Category:Width</string>
- </key>
- <value>
- <string>System.Int32:80</string>
- </value>
- </item>
- <item>
- <key>
- <string>olvJobs/Category:LastDisplayIndex</string>
- </key>
- <value>
- <string>System.Int32:15</string>
- </value>
- </item>
- <item>
- <key>
- <string>olvJobs/Status:Visibility</string>
- </key>
- <value>
- <string>System.Boolean:True</string>
- </value>
- </item>
- <item>
- <key>
- <string>olvJobs/Status:Width</string>
- </key>
- <value>
- <string>System.Int32:79</string>
- </value>
- </item>
- <item>
- <key>
- <string>olvJobs/Status:LastDisplayIndex</string>
- </key>
- <value>
- <string>System.Int32:6</string>
- </value>
- </item>
- <item>
- <key>
- <string>olvJobs/LastSortColumn</string>
- </key>
- <value>
- <string>System.String:Application</string>
- </value>
- </item>
- <item>
- <key>
- <string>olvJobs/LastSortOrder</string>
- </key>
- <value>
- <string>System.Int32:1</string>
- </value>
- </item>
- <item>
- <key>
- <string>Ketarin/ShowGroups</string>
- </key>
- <value>
- <string>System.Boolean:True</string>
- </value>
- </item>
- <item>
- <key>
- <string>Ketarin/ShowStatusBar</string>
- </key>
- <value>
- <string>System.Boolean:False</string>
- </value>
- </item>
- <item>
- <key>
- <string>Ketarin/ShowLog</string>
- </key>
- <value>
- <string>System.Boolean:True</string>
- </value>
- </item>
- <item>
- <key>
- <string>Ketarin/AutoScroll</string>
- </key>
- <value>
- <string>System.Boolean:True</string>
- </value>
- </item>
- <item>
- <key>
- <string>PreUpdateCommand</string>
- </key>
- <value>
- <string>System.String:REM https://chocolatey.org/packages/chocolateypackageupdater
- chocopkgup {nopush} {force} --pf="{autoPackagesFolder}" --packagename="{appname}" --version="{version}" --url="{preupdate-url}" --urlx64="{url64}" --checksum="{checksum}" --c64="{checksumx64}" --debug</string>
- </value>
- </item>
- <item>
- <key>
- <string>PreUpdateCommandType</string>
- </key>
- <value>
- <string>System.String:Batch</string>
- </value>
- </item>
- <item>
- <key>
- <string>CustomColumns</string>
- </key>
- <value>
- <string>System.String:<?xml version="1.0" encoding="utf-16"?>
- <dictionary>
- <item>
- <key>
- <string>version</string>
- </key>
- <value>
- <string>{version}</string>
- </value>
- </item>
- <item>
- <key>
- <string>filesize</string>
- </key>
- <value>
- <string>{filesize:formatfilesize}</string>
- </value>
- </item>
- <item>
- <key>
- <string>host</string>
- </key>
- <value>
- <string>{url:regex:(?&lt;=//)([\w-]+\.)*(?=[\w-]+\.[\w-]+(?=/))}</string>
- </value>
- </item>
- <item>
- <key>
- <string>fileDate</string>
- </key>
- <value>
- <string>{f:yyyy}-{f:MM}-{f:dd} {f:HH}:{f:mm}</string>
- </value>
- </item>
- <item>
- <key>
- <string>fixedUrl</string>
- </key>
- <value>
- <string>{property:FixedDownloadUrl:regex:(?&lt;=//).*}</string>
- </value>
- </item>
- <item>
- <key>
- <string>referer</string>
- </key>
- <value>
- <string>{property:HttpReferer}</string>
- </value>
- </item>
- <item>
- <key>
- <string>user-agent</string>
- </key>
- <value>
- <string>{property:UserAgent}</string>
- </value>
- </item>
- <item>
- <key>
- <string>delPrevFile</string>
- </key>
- <value>
- <string>{property:DeletePreviousFile:multireplace:,:True,False:X,}</string>
- </value>
- </item>
- <item>
- <key>
- <string>varChgInd</string>
- </key>
- <value>
- <string>{property:VariableChangeIndicator}</string>
- </value>
- </item>
- <item>
- <key>
- <string>cscript</string>
- </key>
- <value>
- <string>{cscript}</string>
- </value>
- </item>
- <item>
- <key>
- <string>enabled</string>
- </key>
- <value>
- <string>{property:Enabled}</string>
- </value>
- </item>
- <item>
- <key>
- <string>nopush</string>
- </key>
- <value>
- <string>{nopush}</string>
- </value>
- </item>
- <item>
- <key>
- <string>domain</string>
- </key>
- <value>
- <string>{url:regex:(?&lt;=//[\w-]+\.)*[\w-]+\.[\w-]+(?=/)}</string>
- </value>
- </item>
- <item>
- <key>
- <string>url64</string>
- </key>
- <value>
- <string>{url64}</string>
- </value>
- </item>
- <item>
- <key>
- <string>hashInternal</string>
- </key>
- <value>
- <string>{hash}</string>
- </value>
- </item>
- <item>
- <key>
- <string>hashType</string>
- </key>
- <value>
- <string>{property:HashType:replace:None:}</string>
- </value>
- </item>
- <item>
- <key>
- <string>proto</string>
- </key>
- <value>
- <string>{url:regex:.*?(?=.//)}</string>
- </value>
- </item>
- <item>
- <key>
- <string>bytes</string>
- </key>
- <value>
- <string>{filesize}</string>
- </value>
- </item>
- <item>
- <key>
- <string>hashExternal</string>
- </key>
- <value>
- <string>{checksum}</string>
- </value>
- </item>
- <item>
- <key>
- <string>checksum64</string>
- </key>
- <value>
- <string>{checksumx64}</string>
- </value>
- </item>
- </dictionary></string>
- </value>
- </item>
- <item>
- <key>
- <string>CustomColumn</string>
- </key>
- <value>
- <string p6:nil="true" xmlns:p6="http://www.w3.org/2001/XMLSchema-instance" />
- </value>
- </item>
- <item>
- <key>
- <string>CustomColumn2</string>
- </key>
- <value>
- <string p6:nil="true" xmlns:p6="http://www.w3.org/2001/XMLSchema-instance" />
- </value>
- </item>
- <item>
- <key>
- <string>UpdateAtStartup</string>
- </key>
- <value>
- <string>System.Boolean:False</string>
- </value>
- </item>
- <item>
- <key>
- <string>AvoidFileHippoBeta</string>
- </key>
- <value>
- <string>System.Boolean:True</string>
- </value>
- </item>
- <item>
- <key>
- <string>ConnectionTimeout</string>
- </key>
- <value>
- <string>AAEAAAD/////AQAAAAAAAAAEAQAAAA5TeXN0ZW0uRGVjaW1hbAQAAAAFZmxhZ3MCaGkCbG8DbWlkAAAAAAgICAgAAAAAAAAAADwAAAAAAAAACw==</string>
- </value>
- </item>
- <item>
- <key>
- <string>ThreadCount</string>
- </key>
- <value>
- <string>System.Int32:4</string>
- </value>
- </item>
- <item>
- <key>
- <string>RetryCount</string>
- </key>
- <value>
- <string>System.Int32:2</string>
- </value>
- </item>
- <item>
- <key>
- <string>UpdateOnlineDatabase</string>
- </key>
- <value>
- <string>System.Boolean:False</string>
- </value>
- </item>
- <item>
- <key>
- <string>MinimizeToTray</string>
- </key>
- <value>
- <string>System.Boolean:True</string>
- </value>
- </item>
- <item>
- <key>
- <string>CreateDatabaseBackups</string>
- </key>
- <value>
- <string>System.Boolean:True</string>
- </value>
- </item>
- <item>
- <key>
- <string>OpenWebsiteOnDoubleClick</string>
- </key>
- <value>
- <string>System.Boolean:False</string>
- </value>
- </item>
- <item>
- <key>
- <string>ProxyPort</string>
- </key>
- <value>
- <string>AAEAAAD/////AQAAAAAAAAAEAQAAAA5TeXN0ZW0uRGVjaW1hbAQAAAAFZmxhZ3MCaGkCbG8DbWlkAAAAAAgICAgAAAAAAAAAALgiAAAAAAAACw==</string>
- </value>
- </item>
- <item>
- <key>
- <string>ProxyServer</string>
- </key>
- <value>
- <string>System.String:</string>
- </value>
- </item>
- <item>
- <key>
- <string>ProxyUser</string>
- </key>
- <value>
- <string>System.String:</string>
- </value>
- </item>
- <item>
- <key>
- <string>ProxyPassword</string>
- </key>
- <value>
- <string>System.String:</string>
- </value>
- </item>
- <item>
- <key>
- <string>olvJobs/Version:Visibility</string>
- </key>
- <value>
- <string>System.Boolean:True</string>
- </value>
- </item>
- <item>
- <key>
- <string>olvJobs/Version:Width</string>
- </key>
- <value>
- <string>System.Int32:99</string>
- </value>
- </item>
- <item>
- <key>
- <string>olvJobs/Version:LastDisplayIndex</string>
- </key>
- <value>
- <string>System.Int32:1</string>
- </value>
- </item>
- <item>
- <key>
- <string>SetPlaceholderDialog/Size</string>
- </key>
- <value>
- <string>System.Drawing.Size:699,157</string>
- </value>
- </item>
- <item>
- <key>
- <string>SetPlaceholderDialog/Location</string>
- </key>
- <value>
- <string>System.Drawing.Point:0,0</string>
- </value>
- </item>
- <item>
- <key>
- <string>SetPlaceholderDialog/WindowState</string>
- </key>
- <value>
- <string>System.Int32:0</string>
- </value>
- </item>
- <item>
- <key>
- <string>EditVariablesDialog/Size</string>
- </key>
- <value>
- <string>System.Drawing.Size:1004,492</string>
- </value>
- </item>
- <item>
- <key>
- <string>EditVariablesDialog/Location</string>
- </key>
- <value>
- <string>System.Drawing.Point:66,65</string>
- </value>
- </item>
- <item>
- <key>
- <string>EditVariablesDialog/WindowState</string>
- </key>
- <value>
- <string>System.Int32:0</string>
- </value>
- </item>
- <item>
- <key>
- <string>ApplicationJobDialog/Size</string>
- </key>
- <value>
- <string>System.Drawing.Size:507,507</string>
- </value>
- </item>
- <item>
- <key>
- <string>ApplicationJobDialog/Location</string>
- </key>
- <value>
- <string>System.Drawing.Point:173,12</string>
- </value>
- </item>
- <item>
- <key>
- <string>ApplicationJobDialog/WindowState</string>
- </key>
- <value>
- <string>System.Int32:0</string>
- </value>
- </item>
- <item>
- <key>
- <string>LogDialog/Size</string>
- </key>
- <value>
- <string>System.Drawing.Size:1143,423</string>
- </value>
- </item>
- <item>
- <key>
- <string>LogDialog/Location</string>
- </key>
- <value>
- <string>System.Drawing.Point:116,360</string>
- </value>
- </item>
- <item>
- <key>
- <string>LogDialog/WindowState</string>
- </key>
- <value>
- <string>System.Int32:0</string>
- </value>
- </item>
- <item>
- <key>
- <string>ErrorsDialog/Size</string>
- </key>
- <value>
- <string>System.Drawing.Size:1096,965</string>
- </value>
- </item>
- <item>
- <key>
- <string>olvErrors/Application:Visibility</string>
- </key>
- <value>
- <string>System.Boolean:True</string>
- </value>
- </item>
- <item>
- <key>
- <string>olvErrors/Application:Width</string>
- </key>
- <value>
- <string>System.Int32:98</string>
- </value>
- </item>
- <item>
- <key>
- <string>olvErrors/Application:LastDisplayIndex</string>
- </key>
- <value>
- <string>System.Int32:-1</string>
- </value>
- </item>
- <item>
- <key>
- <string>olvErrors/Error:Visibility</string>
- </key>
- <value>
- <string>System.Boolean:True</string>
- </value>
- </item>
- <item>
- <key>
- <string>olvErrors/Error:Width</string>
- </key>
- <value>
- <string>System.Int32:952</string>
- </value>
- </item>
- <item>
- <key>
- <string>olvErrors/Error:LastDisplayIndex</string>
- </key>
- <value>
- <string>System.Int32:-1</string>
- </value>
- </item>
- <item>
- <key>
- <string>olvErrors/LastSortColumn</string>
- </key>
- <value>
- <string>System.String:Application</string>
- </value>
- </item>
- <item>
- <key>
- <string>olvErrors/LastSortOrder</string>
- </key>
- <value>
- <string>System.Int32:1</string>
- </value>
- </item>
- <item>
- <key>
- <string>ProgressDialog/Size</string>
- </key>
- <value>
- <string>System.Drawing.Size:302,112</string>
- </value>
- </item>
- <item>
- <key>
- <string>Hotkey: OpenWebsite</string>
- </key>
- <value>
- <string>System.String:</string>
- </value>
- </item>
- <item>
- <key>
- <string>Hotkey: Edit</string>
- </key>
- <value>
- <string>System.String:</string>
- </value>
- </item>
- <item>
- <key>
- <string>Hotkey: Update</string>
- </key>
- <value>
- <string>System.String:</string>
- </value>
- </item>
- <item>
- <key>
- <string>Hotkey: ForceDownload</string>
- </key>
- <value>
- <string>System.String:</string>
- </value>
- </item>
- <item>
- <key>
- <string>Hotkey: InstallSelected</string>
- </key>
- <value>
- <string>System.String:</string>
- </value>
- </item>
- <item>
- <key>
- <string>Hotkey: OpenFile</string>
- </key>
- <value>
- <string>System.String:</string>
- </value>
- </item>
- <item>
- <key>
- <string>Hotkey: OpenFolder</string>
- </key>
- <value>
- <string>System.String:</string>
- </value>
- </item>
- <item>
- <key>
- <string>Hotkey: CheckUpdate</string>
- </key>
- <value>
- <string>System.String:</string>
- </value>
- </item>
- <item>
- <key>
- <string>Hotkey: UpdateAndInstall</string>
- </key>
- <value>
- <string>System.String:</string>
- </value>
- </item>
- <item>
- <key>
- <string>InstallingApplicationsDialog/Size</string>
- </key>
- <value>
- <string>System.Drawing.Size:406,250</string>
- </value>
- </item>
- <item>
- <key>
- <string>InstallingApplicationsDialog/Location</string>
- </key>
- <value>
- <string>System.Drawing.Point:164,724</string>
- </value>
- </item>
- <item>
- <key>
- <string>InstallingApplicationsDialog/WindowState</string>
- </key>
- <value>
- <string>System.Int32:0</string>
- </value>
- </item>
- <item>
- <key>
- <string>olvLog/Time:Visibility</string>
- </key>
- <value>
- <string>System.Boolean:True</string>
- </value>
- </item>
- <item>
- <key>
- <string>olvLog/Time:Width</string>
- </key>
- <value>
- <string>System.Int32:55</string>
- </value>
- </item>
- <item>
- <key>
- <string>olvLog/Time:LastDisplayIndex</string>
- </key>
- <value>
- <string>System.Int32:-1</string>
- </value>
- </item>
- <item>
- <key>
- <string>olvLog/Message:Visibility</string>
- </key>
- <value>
- <string>System.Boolean:True</string>
- </value>
- </item>
- <item>
- <key>
- <string>olvLog/Message:Width</string>
- </key>
- <value>
- <string>System.Int32:310</string>
- </value>
- </item>
- <item>
- <key>
- <string>olvLog/Message:LastDisplayIndex</string>
- </key>
- <value>
- <string>System.Int32:-1</string>
- </value>
- </item>
- <item>
- <key>
- <string>olvLog/LastSortColumn</string>
- </key>
- <value>
- <string>System.String:Time</string>
- </value>
- </item>
- <item>
- <key>
- <string>olvLog/LastSortOrder</string>
- </key>
- <value>
- <string>System.Int32:0</string>
- </value>
- </item>
- <item>
- <key>
- <string>InstallingApplicationsDialog/Expanded</string>
- </key>
- <value>
- <string>System.Boolean:True</string>
- </value>
- </item>
- <item>
- <key>
- <string>DefaultCommand</string>
- </key>
- <value>
- <string>System.String:////////////////////////////////////////////////////////////////////////////////////////
- /// version ? Lots of changes
- ///
- /// Changelog:
- /// - Allow for non-versioned output folder paths
- /// - Logging!
- /// - Call choco directly, expected to be at the default location.
- ///
- // REQUIRES:
- // global vars: saveDir=corresponds to download location of installer file
- // app vars: nopush, checksum64file=corresponds to 64 bit install file
- // file vars: same as specified by chocopkgup
- // get package variable 'cscript'
- string varCScript = "";
- varCScript = app.Variables.ReplaceAllInString("{cscript}").Trim();
- Ketarin.Forms.LogDialog.Log(app,"cscript='" + varCScript + "'");
- Ketarin.Forms.LogDialog.Log(app,"If cscript is set to 1, checksums will be calculated but the package won't be pushed.");
- Ketarin.Forms.LogDialog.Log(app,"If cscript is set to 2, checksums will be calculated AND the package will be pushed.");
- // determine whether we run this by checking cscript exists AND is 1 or 2
- if ((varCScript == "1") || (varCScript == "2"))
- {
- // ketarin variables we pass for this script to use
- string varAppname = app.Variables.ReplaceAllInString("{appname}");
- string varVersion = app.Variables.ReplaceAllInString("{version}");
- string varChocoPkgOutput = System.IO.Path.Combine(app.Variables.ReplaceAllInString("{autoPackagesFolder}"), "_output");
- string varChecksum = app.Variables.ReplaceAllInString("{checksum}");
- string varChecksumx64 = app.Variables.ReplaceAllInString("{checksumx64}");
- string varChecksum64File = app.Variables.ReplaceAllInString("{url64}");
- string varSaveDir = app.Variables.ReplaceAllInString("{saveDir}");
- // custom variables used in this script
- // equivalent to ketarin variable "{file}"
- string savePath = app.PreviousLocation;
- string pkgPath = System.IO.Path.Combine(varChocoPkgOutput, varAppname, varVersion);
- if (!System.IO.Directory.Exists(pkgPath))
- {
- pkgPath = System.IO.Path.Combine(varChocoPkgOutput, varAppname);
- Ketarin.Forms.LogDialog.Log(app,"Using the output folder without a version");
- }
- Ketarin.Forms.LogDialog.Log(app, "Using package file at " + pkgPath);
- string fileNameNuspec = System.String.Concat(varAppname, ".nuspec");
- string fileUriNuspec = System.IO.Path.Combine(pkgPath, fileNameNuspec);
- string fileNameNupkg = System.String.Concat(varAppname, ".", varVersion, ".nupkg");
- string fileUriNupkg = System.IO.Path.Combine(pkgPath, fileNameNupkg);
- //MessageBox.Show("pkgPath=" + pkgPath + System.Environment.NewLine
- // + "savePath=" + savePath);
- // do not re-push package if package already created
- System.DateTime today = System.DateTime.Today;
- System.DateTime pkgCreateDate = System.IO.File.GetCreationTime(pkgPath);
- if (today > pkgCreateDate)
- {
- return;
- }
- // calculate SHA256 from {url} Note we are leveraging ketarin's downloaded copy
- System.IO.FileStream fileSha = new System.IO.FileStream(savePath, System.IO.FileMode.Open);
- System.Security.Cryptography.SHA256 sha256 = new System.Security.Cryptography.SHA256Managed();
- byte[] retValSha = sha256.ComputeHash(fileSha);
- fileSha.Close();
- // build string from byte value
- System.Text.StringBuilder sbSha = new System.Text.StringBuilder();
- for (int i = 0; i < retValSha.Length; i++)
- {
- sbSha.Append(retValSha[i].ToString("x2"));
- }
- // find $pkgPath -iname "*.nuspec" -o -iname "*.ps1" -exec sed -i 's/'$sbSha'/{checksum}/g' '{}' \;
- string replaceChecksum = sbSha.ToString();
- Ketarin.Forms.LogDialog.Log(app, "Checksum for url is " + replaceChecksum);
- //MessageBox.Show(replaceChecksum);
- System.Collections.Generic.List<string> pkgFileList = new System.Collections.Generic.List<string>(System.IO.Directory.GetFiles(pkgPath, "*.ps1", System.IO.SearchOption.AllDirectories));
- string[] filesNuspec = System.IO.Directory.GetFiles(pkgPath, "*.nuspec", System.IO.SearchOption.AllDirectories);
- pkgFileList.AddRange(filesNuspec);
- string[] files = pkgFileList.ToArray();
- foreach (string file in files)
- {
- try
- {
- string contents = System.IO.File.ReadAllText(file);
- //MessageBox.Show(contents);
- contents = contents.Replace("{checksum}", replaceChecksum);
- //MessageBox.Show(contents);
- // Make files writable
- // File.SetAttributes(file, FileAttributes.Normal);
- System.IO.File.WriteAllText(file, contents);
- }
- catch (System.Exception ex)
- {
- System.Console.WriteLine(ex.Message);
- }
- }
- // Get Checksum for 64bit file if url64 exists
- if (varChecksum64File != "{url64}" && varChecksum64File != "\"\"" && !System.String.IsNullOrEmpty(varChecksum64File))
- {
- // TODO: verify and validate URI checksum64file points to a downloadable file
- // string varChecksum64basefile = app.Variables.ReplaceAllInString("{url64:basefile}");
- string varChecksum64ext = app.Variables.ReplaceAllInString("{url64:ext}");
- string saveFileName64 = System.String.Concat(varAppname, "_64_", varVersion, ".", varChecksum64ext);
- string savePath64 = System.IO.Path.Combine(varSaveDir, saveFileName64);
- // we must download the file to calculate checksum ... may as well save it
- Ketarin.Forms.LogDialog.Log(app, "Downloading '" + varChecksum64File + "' to '" + savePath64 + "'.");
- System.Net.WebClient webClient = new System.Net.WebClient();
- webClient.DownloadFile(varChecksum64File, savePath64);
- // calculate SHA256 from file of url pointed to by 'checksum64file'
- System.IO.FileStream file64Sha = new System.IO.FileStream(savePath64, System.IO.FileMode.Open);
- System.Security.Cryptography.SHA256 sha256_64 = new System.Security.Cryptography.SHA256Managed();
- byte[] retVal64Sha = sha256_64.ComputeHash(file64Sha);
- file64Sha.Close();
- // build string from byte value
- System.Text.StringBuilder sb64Sha = new System.Text.StringBuilder();
- for (int i = 0; i < retVal64Sha.Length; i++)
- {
- sb64Sha.Append(retVal64Sha[i].ToString("x2"));
- }
- // find $pkgPath -iname "*.nuspec" -o -iname "*.ps1" -exec sed -i 's/'$sb64Sha'/{checksumx64}/g' '{}' \;
- // Note chocopkgup will strip 1 set of curly braces so {{checksum}} becomes {checksum}
- string replace64Checksum = sb64Sha.ToString();
- Ketarin.Forms.LogDialog.Log(app, "Checksum for url64 is " + replace64Checksum);
- foreach (string file in files)
- {
- try
- {
- string contents = System.IO.File.ReadAllText(file);
- //MessageBox.Show(contents);
- contents = contents.Replace("{checksumx64}", replace64Checksum);
- //MessageBox.Show(contents);
- System.IO.File.WriteAllText(file, contents);
- }
- catch (System.Exception ex)
- {
- System.Console.WriteLine(ex.Message);
- }
- }
- }
- // delete existing nupkg made by chocopkgup; we leverage chocopkgup to create the structure/files in destination
- Ketarin.Forms.LogDialog.Log(app, "Deleting the existing nupkg before repacking at " + fileUriNupkg);
- System.Diagnostics.Process process1 = new System.Diagnostics.Process();
- System.Diagnostics.ProcessStartInfo proc1 = new System.Diagnostics.ProcessStartInfo();
- proc1.WindowStyle = System.Diagnostics.ProcessWindowStyle.Hidden;
- proc1.UseShellExecute = true;
- proc1.WorkingDirectory = pkgPath;
- proc1.FileName = "cmd.exe";
- proc1.Arguments = "/c " + "del /f " + fileUriNupkg;
- process1.StartInfo = proc1;
- process1.Start();
- process1.WaitForExit(30000);
- // create a new nupkg
- Ketarin.Forms.LogDialog.Log(app, "Packing up the package, this time with checksums");
- System.Diagnostics.Process process2 = new System.Diagnostics.Process();
- System.Diagnostics.ProcessStartInfo proc2 = new System.Diagnostics.ProcessStartInfo();
- proc2.WindowStyle = System.Diagnostics.ProcessWindowStyle.Minimized;
- proc2.UseShellExecute = false;
- proc2.WorkingDirectory = pkgPath;
- proc2.FileName = "C:\\ProgramData\\Chocolatey\\bin\\choco.exe";
- proc2.Arguments = "pack " + fileUriNuspec;
- proc2.RedirectStandardOutput = true;
- proc2.RedirectStandardError = true;
- proc2.CreateNoWindow = true;
- process2.StartInfo = proc2;
- process2.OutputDataReceived += (s, e) => { if (e != null) Ketarin.Forms.LogDialog.Log(app, e.Data); };
- process2.ErrorDataReceived += (s, e) => { if (e != null) Ketarin.Forms.LogDialog.Log(app, e.Data); };
- process2.EnableRaisingEvents = true;
- process2.Start();
- process2.BeginErrorReadLine();
- process2.BeginOutputReadLine();
- process2.WaitForExit(30000);
- process2.StartInfo = proc2;
- process2.Start();
- // push the nupkg
- if (varCScript == "2")
- {
- System.Threading.Thread.Sleep(2000);
- System.Int32 exitCode = -1;
- Ketarin.Forms.LogDialog.Log(app, "Pushing the package");
- System.Diagnostics.Process process3 = new System.Diagnostics.Process();
- System.Diagnostics.ProcessStartInfo proc3 = new System.Diagnostics.ProcessStartInfo();
- proc3.WindowStyle = System.Diagnostics.ProcessWindowStyle.Minimized;
- proc3.UseShellExecute = false;
- proc3.WorkingDirectory = pkgPath;
- proc3.FileName = "C:\\ProgramData\\Chocolatey\\bin\\choco.exe";
- // find nupkg in pkgPath
- string[] pushPkg = System.IO.Directory.GetFiles(pkgPath, "*.nupkg", System.IO.SearchOption.TopDirectoryOnly);
- foreach (System.String file in pushPkg)
- {
- Ketarin.Forms.LogDialog.Log(app, "Pushing " + file + " to dot org");
- proc3.Arguments = "push " + file;
- }
- proc3.RedirectStandardOutput = true;
- proc3.RedirectStandardError = true;
- proc3.CreateNoWindow = true;
- process3.StartInfo = proc3;
- process3.OutputDataReceived += (s, e) => { if (e != null) Ketarin.Forms.LogDialog.Log(app, e.Data); };
- process3.ErrorDataReceived += (s, e) => { if (e != null) Ketarin.Forms.LogDialog.Log(app, e.Data); };
- process3.EnableRaisingEvents = true;
- process3.Start();
- process3.BeginErrorReadLine();
- process3.BeginOutputReadLine();
- System.Boolean exited = process3.WaitForExit(120000);
- if (exited)
- {
- exitCode = process3.ExitCode;
- }
- if (exitCode != 0)
- {
- throw new System.Exception("Push did not finish successfully. See the log for details.");
- Ketarin.Forms.LogDialog.Log(app, "This is a failure. However Ketarin doesn't error on post updates.");
- }
- }
- }</string>
- </value>
- </item>
- <item>
- <key>
- <string>DefaultCommandType</string>
- </key>
- <value>
- <string>System.String:CS</string>
- </value>
- </item>
- <item>
- <key>
- <string>PostUpdateCommand</string>
- </key>
- <value>
- <string>System.String:</string>
- </value>
- </item>
- <item>
- <key>
- <string>PostUpdateCommandType</string>
- </key>
- <value>
- <string>System.String:Batch</string>
- </value>
- </item>
- <item>
- <key>
- <string>DefaultApplication</string>
- </key>
- <value>
- <string>System.String:<?xml version="1.0" encoding="utf-8"?>
- <Jobs>
- <ApplicationJob xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xmlns:xsd="http://www.w3.org/2001/XMLSchema">
- <WebsiteUrl />
- <UserAgent />
- <UserNotes />
- <LastFileSize>0</LastFileSize>
- <LastFileDate xsi:nil="true" />
- <IgnoreFileInformation>false</IgnoreFileInformation>
- <DownloadBeta>Default</DownloadBeta>
- <CheckForUpdatesOnly>false</CheckForUpdatesOnly>
- <VariableChangeIndicator />
- <HashVariable />
- <HashType>None</HashType>
- <CanBeShared>true</CanBeShared>
- <ShareApplication>false</ShareApplication>
- <ExclusiveDownload>false</ExclusiveDownload>
- <HttpReferer />
- <SetupInstructions />
- <Variables>
- <item>
- <key>
- <string>nopush</string>
- </key>
- <value>
- <UrlVariable>
- <RegexRightToLeft>false</RegexRightToLeft>
- <VariableType>Textual</VariableType>
- <Regex />
- <TextualContent>--nopush</TextualContent>
- <Name>nopush</Name>
- </UrlVariable>
- </value>
- </item>
- <item>
- <key>
- <string>version</string>
- </key>
- <value>
- <UrlVariable>
- <RegexRightToLeft>false</RegexRightToLeft>
- <VariableType>RegularExpression</VariableType>
- <Regex>Last program version.*?([\d\.]+)</Regex>
- <Url>x</Url>
- <Name>version</Name>
- </UrlVariable>
- </value>
- </item>
- <item>
- <key>
- <string>url</string>
- </key>
- <value>
- <UrlVariable>
- <RegexRightToLeft>false</RegexRightToLeft>
- <VariableType>Textual</VariableType>
- <Regex />
- <TextualContent>{getUrl}</TextualContent>
- <Name>url</Name>
- </UrlVariable>
- </value>
- </item>
- <item>
- <key>
- <string>url64</string>
- </key>
- <value>
- <UrlVariable>
- <RegexRightToLeft>false</RegexRightToLeft>
- <VariableType>Textual</VariableType>
- <Regex />
- <TextualContent>{getUrl64}</TextualContent>
- <Name>url64</Name>
- </UrlVariable>
- </value>
- </item>
- <item>
- <key>
- <string>getUrl</string>
- </key>
- <value>
- <UrlVariable>
- <RegexRightToLeft>false</RegexRightToLeft>
- <VariableType>RegularExpression</VariableType>
- <Regex>[^ "'&lt;&gt;\*]+\.exe</Regex>
- <Url>x</Url>
- <Name>getUrl</Name>
- </UrlVariable>
- </value>
- </item>
- <item>
- <key>
- <string>getUrl64</string>
- </key>
- <value>
- <UrlVariable>
- <RegexRightToLeft>false</RegexRightToLeft>
- <VariableType>RegularExpression</VariableType>
- <Regex>[^ "'&lt;&gt;\*]+\.exe</Regex>
- <Url>x</Url>
- <Name>getUrl64</Name>
- </UrlVariable>
- </value>
- </item>
- <item>
- <key>
- <string>checksum</string>
- </key>
- <value>
- <UrlVariable>
- <RegexRightToLeft>false</RegexRightToLeft>
- <VariableType>RegularExpression</VariableType>
- <Regex>[A-Fa-f0-9]{32}</Regex>
- <Url>md5</Url>
- <TextualContent>{checksum}</TextualContent>
- <Name>checksum</Name>
- </UrlVariable>
- </value>
- </item>
- <item>
- <key>
- <string>checksumx64</string>
- </key>
- <value>
- <UrlVariable>
- <RegexRightToLeft>false</RegexRightToLeft>
- <VariableType>RegularExpression</VariableType>
- <Regex>(?&lt;=ResponseUri: )[^\r\n]+</Regex>
- <Url>{url64}</Url>
- <TextualContent>{checksum}</TextualContent>
- <Name>checksumx64</Name>
- </UrlVariable>
- </value>
- </item>
- <item>
- <key>
- <string>checksum64file</string>
- </key>
- <value>
- <UrlVariable>
- <RegexRightToLeft>false</RegexRightToLeft>
- <VariableType>Textual</VariableType>
- <Regex />
- <TextualContent>{url64}</TextualContent>
- <Name>checksum64file</Name>
- </UrlVariable>
- </value>
- </item>
- <item>
- <key>
- <string>cscript</string>
- </key>
- <value>
- <UrlVariable>
- <RegexRightToLeft>false</RegexRightToLeft>
- <VariableType>Textual</VariableType>
- <Regex />
- <TextualContent>0</TextualContent>
- <Name>cscript</Name>
- </UrlVariable>
- </value>
- </item>
- </Variables>
- <ExecuteCommand />
- <ExecutePreCommand />
- <ExecuteCommandType>Batch</ExecuteCommandType>
- <ExecutePreCommandType>Batch</ExecutePreCommandType>
- <Category />
- <SourceType>FixedUrl</SourceType>
- <DeletePreviousFile>false</DeletePreviousFile>
- <Enabled>true</Enabled>
- <FileHippoId />
- <TargetPath>{saveDir}\{appname}_{version}.{url:ext}</TargetPath>
- <FixedDownloadUrl>{url}</FixedDownloadUrl>
- <Name>x </Name>
- </ApplicationJob>
- </Jobs></string>
- </value>
- </item>
- <item>
- <key>
- <string>olvJobs/x:Visibility</string>
- </key>
- <value>
- <string>System.Boolean:True</string>
- </value>
- </item>
- <item>
- <key>
- <string>olvJobs/x:Width</string>
- </key>
- <value>
- <string>System.Int32:89</string>
- </value>
- </item>
- <item>
- <key>
- <string>olvJobs/x:LastDisplayIndex</string>
- </key>
- <value>
- <string>System.Int32:-1</string>
- </value>
- </item>
- <item>
- <key>
- <string>olvJobs/Filesize:Visibility</string>
- </key>
- <value>
- <string>System.Boolean:True</string>
- </value>
- </item>
- <item>
- <key>
- <string>olvJobs/Filesize:Width</string>
- </key>
- <value>
- <string>System.Int32:68</string>
- </value>
- </item>
- <item>
- <key>
- <string>olvJobs/Filesize:LastDisplayIndex</string>
- </key>
- <value>
- <string>System.Int32:5</string>
- </value>
- </item>
- <item>
- <key>
- <string>olvJobs/url:Visibility</string>
- </key>
- <value>
- <string>System.Boolean:True</string>
- </value>
- </item>
- <item>
- <key>
- <string>olvJobs/url:Width</string>
- </key>
- <value>
- <string>System.Int32:147</string>
- </value>
- </item>
- <item>
- <key>
- <string>olvJobs/url:LastDisplayIndex</string>
- </key>
- <value>
- <string>System.Int32:-1</string>
- </value>
- </item>
- <item>
- <key>
- <string>olvJobs/host:Visibility</string>
- </key>
- <value>
- <string>System.Boolean:True</string>
- </value>
- </item>
- <item>
- <key>
- <string>olvJobs/host:Width</string>
- </key>
- <value>
- <string>System.Int32:120</string>
- </value>
- </item>
- <item>
- <key>
- <string>olvJobs/host:LastDisplayIndex</string>
- </key>
- <value>
- <string>System.Int32:10</string>
- </value>
- </item>
- <item>
- <key>
- <string>olvJobs/packageGuid:Visibility</string>
- </key>
- <value>
- <string>System.Boolean:True</string>
- </value>
- </item>
- <item>
- <key>
- <string>olvJobs/packageGuid:Width</string>
- </key>
- <value>
- <string>System.Int32:77</string>
- </value>
- </item>
- <item>
- <key>
- <string>olvJobs/packageGuid:LastDisplayIndex</string>
- </key>
- <value>
- <string>System.Int32:14</string>
- </value>
- </item>
- <item>
- <key>
- <string>olvJobs/fileDate:Visibility</string>
- </key>
- <value>
- <string>System.Boolean:True</string>
- </value>
- </item>
- <item>
- <key>
- <string>olvJobs/fileDate:Width</string>
- </key>
- <value>
- <string>System.Int32:97</string>
- </value>
- </item>
- <item>
- <key>
- <string>olvJobs/fileDate:LastDisplayIndex</string>
- </key>
- <value>
- <string>System.Int32:3</string>
- </value>
- </item>
- <item>
- <key>
- <string>olvJobs/fixedUrl:Visibility</string>
- </key>
- <value>
- <string>System.Boolean:True</string>
- </value>
- </item>
- <item>
- <key>
- <string>olvJobs/fixedUrl:Width</string>
- </key>
- <value>
- <string>System.Int32:96</string>
- </value>
- </item>
- <item>
- <key>
- <string>olvJobs/fixedUrl:LastDisplayIndex</string>
- </key>
- <value>
- <string>System.Int32:9</string>
- </value>
- </item>
- <item>
- <key>
- <string>olvJobs/referer:Visibility</string>
- </key>
- <value>
- <string>System.Boolean:True</string>
- </value>
- </item>
- <item>
- <key>
- <string>olvJobs/referer:Width</string>
- </key>
- <value>
- <string>System.Int32:65</string>
- </value>
- </item>
- <item>
- <key>
- <string>olvJobs/referer:LastDisplayIndex</string>
- </key>
- <value>
- <string>System.Int32:13</string>
- </value>
- </item>
- <item>
- <key>
- <string>olvJobs/User-Agent:Visibility</string>
- </key>
- <value>
- <string>System.Boolean:True</string>
- </value>
- </item>
- <item>
- <key>
- <string>olvJobs/User-Agent:Width</string>
- </key>
- <value>
- <string>System.Int32:80</string>
- </value>
- </item>
- <item>
- <key>
- <string>olvJobs/User-Agent:LastDisplayIndex</string>
- </key>
- <value>
- <string>System.Int32:8</string>
- </value>
- </item>
- <item>
- <key>
- <string>olvJobs/DeletePreviousFile:Visibility</string>
- </key>
- <value>
- <string>System.Boolean:True</string>
- </value>
- </item>
- <item>
- <key>
- <string>olvJobs/DeletePreviousFile:Width</string>
- </key>
- <value>
- <string>System.Int32:41</string>
- </value>
- </item>
- <item>
- <key>
- <string>olvJobs/DeletePreviousFile:LastDisplayIndex</string>
- </key>
- <value>
- <string>System.Int32:20</string>
- </value>
- </item>
- <item>
- <key>
- <string>olvJobs/VariableChangeIndicator:Visibility</string>
- </key>
- <value>
- <string>System.Boolean:True</string>
- </value>
- </item>
- <item>
- <key>
- <string>olvJobs/VariableChangeIndicator:Width</string>
- </key>
- <value>
- <string>System.Int32:55</string>
- </value>
- </item>
- <item>
- <key>
- <string>olvJobs/VariableChangeIndicator:LastDisplayIndex</string>
- </key>
- <value>
- <string>System.Int32:15</string>
- </value>
- </item>
- <item>
- <key>
- <string>olvJobs/github:Visibility</string>
- </key>
- <value>
- <string>System.Boolean:True</string>
- </value>
- </item>
- <item>
- <key>
- <string>olvJobs/github:Width</string>
- </key>
- <value>
- <string>System.Int32:64</string>
- </value>
- </item>
- <item>
- <key>
- <string>olvJobs/github:LastDisplayIndex</string>
- </key>
- <value>
- <string>System.Int32:16</string>
- </value>
- </item>
- <item>
- <key>
- <string>olvJobs/kde:Visibility</string>
- </key>
- <value>
- <string>System.Boolean:True</string>
- </value>
- </item>
- <item>
- <key>
- <string>olvJobs/kde:Width</string>
- </key>
- <value>
- <string>System.Int32:49</string>
- </value>
- </item>
- <item>
- <key>
- <string>olvJobs/kde:LastDisplayIndex</string>
- </key>
- <value>
- <string>System.Int32:17</string>
- </value>
- </item>
- <item>
- <key>
- <string>olvJobs/cscript:Visibility</string>
- </key>
- <value>
- <string>System.Boolean:True</string>
- </value>
- </item>
- <item>
- <key>
- <string>olvJobs/cscript:Width</string>
- </key>
- <value>
- <string>System.Int32:32</string>
- </value>
- </item>
- <item>
- <key>
- <string>olvJobs/cscript:LastDisplayIndex</string>
- </key>
- <value>
- <string>System.Int32:22</string>
- </value>
- </item>
- <item>
- <key>
- <string>olvJobs/enabled:Visibility</string>
- </key>
- <value>
- <string>System.Boolean:True</string>
- </value>
- </item>
- <item>
- <key>
- <string>olvJobs/enabled:Width</string>
- </key>
- <value>
- <string>System.Int32:60</string>
- </value>
- </item>
- <item>
- <key>
- <string>olvJobs/enabled:LastDisplayIndex</string>
- </key>
- <value>
- <string>System.Int32:26</string>
- </value>
- </item>
- <item>
- <key>
- <string>olvJobs/nopush:Visibility</string>
- </key>
- <value>
- <string>System.Boolean:True</string>
- </value>
- </item>
- <item>
- <key>
- <string>olvJobs/nopush:Width</string>
- </key>
- <value>
- <string>System.Int32:60</string>
- </value>
- </item>
- <item>
- <key>
- <string>olvJobs/nopush:LastDisplayIndex</string>
- </key>
- <value>
- <string>System.Int32:23</string>
- </value>
- </item>
- <item>
- <key>
- <string>olvJobs/domainname:Visibility</string>
- </key>
- <value>
- <string>System.Boolean:True</string>
- </value>
- </item>
- <item>
- <key>
- <string>olvJobs/domainname:Width</string>
- </key>
- <value>
- <string>System.Int32:166</string>
- </value>
- </item>
- <item>
- <key>
- <string>olvJobs/domainname:LastDisplayIndex</string>
- </key>
- <value>
- <string>System.Int32:10</string>
- </value>
- </item>
- <item>
- <key>
- <string>olvJobs/domain:Visibility</string>
- </key>
- <value>
- <string>System.Boolean:True</string>
- </value>
- </item>
- <item>
- <key>
- <string>olvJobs/domain:Width</string>
- </key>
- <value>
- <string>System.Int32:141</string>
- </value>
- </item>
- <item>
- <key>
- <string>olvJobs/domain:LastDisplayIndex</string>
- </key>
- <value>
- <string>System.Int32:17</string>
- </value>
- </item>
- <item>
- <key>
- <string>olvJobs/checksum64file:Visibility</string>
- </key>
- <value>
- <string>System.Boolean:True</string>
- </value>
- </item>
- <item>
- <key>
- <string>olvJobs/checksum64file:Width</string>
- </key>
- <value>
- <string>System.Int32:91</string>
- </value>
- </item>
- <item>
- <key>
- <string>olvJobs/checksum64file:LastDisplayIndex</string>
- </key>
- <value>
- <string>System.Int32:25</string>
- </value>
- </item>
- <item>
- <key>
- <string>olvJobs/Target2:Visibility</string>
- </key>
- <value>
- <string>System.Boolean:True</string>
- </value>
- </item>
- <item>
- <key>
- <string>olvJobs/Target2:Width</string>
- </key>
- <value>
- <string>System.Int32:60</string>
- </value>
- </item>
- <item>
- <key>
- <string>olvJobs/Target2:LastDisplayIndex</string>
- </key>
- <value>
- <string>System.Int32:-1</string>
- </value>
- </item>
- <item>
- <key>
- <string>olvJobs/AppName:Visibility</string>
- </key>
- <value>
- <string>System.Boolean:True</string>
- </value>
- </item>
- <item>
- <key>
- <string>olvJobs/AppName:Width</string>
- </key>
- <value>
- <string>System.Int32:164</string>
- </value>
- </item>
- <item>
- <key>
- <string>olvJobs/AppName:LastDisplayIndex</string>
- </key>
- <value>
- <string>System.Int32:-1</string>
- </value>
- </item>
- <item>
- <key>
- <string>olvJobs/version:Visibility</string>
- </key>
- <value>
- <string>System.Boolean:True</string>
- </value>
- </item>
- <item>
- <key>
- <string>olvJobs/version:Width</string>
- </key>
- <value>
- <string>System.Int32:120</string>
- </value>
- </item>
- <item>
- <key>
- <string>olvJobs/version:LastDisplayIndex</string>
- </key>
- <value>
- <string>System.Int32:1</string>
- </value>
- </item>
- <item>
- <key>
- <string>olvJobs/filesize:Visibility</string>
- </key>
- <value>
- <string>System.Boolean:True</string>
- </value>
- </item>
- <item>
- <key>
- <string>olvJobs/filesize:Width</string>
- </key>
- <value>
- <string>System.Int32:68</string>
- </value>
- </item>
- <item>
- <key>
- <string>olvJobs/filesize:LastDisplayIndex</string>
- </key>
- <value>
- <string>System.Int32:8</string>
- </value>
- </item>
- <item>
- <key>
- <string>olvJobs/user-agent:Visibility</string>
- </key>
- <value>
- <string>System.Boolean:True</string>
- </value>
- </item>
- <item>
- <key>
- <string>olvJobs/user-agent:Width</string>
- </key>
- <value>
- <string>System.Int32:60</string>
- </value>
- </item>
- <item>
- <key>
- <string>olvJobs/user-agent:LastDisplayIndex</string>
- </key>
- <value>
- <string>System.Int32:12</string>
- </value>
- </item>
- <item>
- <key>
- <string>olvJobs/delPrevFile:Visibility</string>
- </key>
- <value>
- <string>System.Boolean:True</string>
- </value>
- </item>
- <item>
- <key>
- <string>olvJobs/delPrevFile:Width</string>
- </key>
- <value>
- <string>System.Int32:60</string>
- </value>
- </item>
- <item>
- <key>
- <string>olvJobs/delPrevFile:LastDisplayIndex</string>
- </key>
- <value>
- <string>System.Int32:27</string>
- </value>
- </item>
- <item>
- <key>
- <string>olvJobs/varChangeIndicator:Visibility</string>
- </key>
- <value>
- <string>System.Boolean:True</string>
- </value>
- </item>
- <item>
- <key>
- <string>olvJobs/varChangeIndicator:Width</string>
- </key>
- <value>
- <string>System.Int32:60</string>
- </value>
- </item>
- <item>
- <key>
- <string>olvJobs/varChangeIndicator:LastDisplayIndex</string>
- </key>
- <value>
- <string>System.Int32:20</string>
- </value>
- </item>
- <item>
- <key>
- <string>olvJobs/varChgInd:Visibility</string>
- </key>
- <value>
- <string>System.Boolean:True</string>
- </value>
- </item>
- <item>
- <key>
- <string>olvJobs/varChgInd:Width</string>
- </key>
- <value>
- <string>System.Int32:82</string>
- </value>
- </item>
- <item>
- <key>
- <string>olvJobs/varChgInd:LastDisplayIndex</string>
- </key>
- <value>
- <string>System.Int32:16</string>
- </value>
- </item>
- <item>
- <key>
- <string>olvJobs/url64:Visibility</string>
- </key>
- <value>
- <string>System.Boolean:True</string>
- </value>
- </item>
- <item>
- <key>
- <string>olvJobs/url64:Width</string>
- </key>
- <value>
- <string>System.Int32:60</string>
- </value>
- </item>
- <item>
- <key>
- <string>olvJobs/url64:LastDisplayIndex</string>
- </key>
- <value>
- <string>System.Int32:24</string>
- </value>
- </item>
- <item>
- <key>
- <string>olvJobs/hash:Visibility</string>
- </key>
- <value>
- <string>System.Boolean:True</string>
- </value>
- </item>
- <item>
- <key>
- <string>olvJobs/hash:Width</string>
- </key>
- <value>
- <string>System.Int32:60</string>
- </value>
- </item>
- <item>
- <key>
- <string>olvJobs/hash:LastDisplayIndex</string>
- </key>
- <value>
- <string>System.Int32:24</string>
- </value>
- </item>
- <item>
- <key>
- <string>olvJobs/hashType:Visibility</string>
- </key>
- <value>
- <string>System.Boolean:True</string>
- </value>
- </item>
- <item>
- <key>
- <string>olvJobs/hashType:Width</string>
- </key>
- <value>
- <string>System.Int32:60</string>
- </value>
- </item>
- <item>
- <key>
- <string>olvJobs/hashType:LastDisplayIndex</string>
- </key>
- <value>
- <string>System.Int32:18</string>
- </value>
- </item>
- <item>
- <key>
- <string>ImportFromDatabaseDialog/Size</string>
- </key>
- <value>
- <string>System.Drawing.Size:524,1596</string>
- </value>
- </item>
- <item>
- <key>
- <string>olvApplications/Application name:Visibility</string>
- </key>
- <value>
- <string>System.Boolean:True</string>
- </value>
- </item>
- <item>
- <key>
- <string>olvApplications/Application name:Width</string>
- </key>
- <value>
- <string>System.Int32:291</string>
- </value>
- </item>
- <item>
- <key>
- <string>olvApplications/Application name:LastDisplayIndex</string>
- </key>
- <value>
- <string>System.Int32:-1</string>
- </value>
- </item>
- <item>
- <key>
- <string>olvApplications/Last updated:Visibility</string>
- </key>
- <value>
- <string>System.Boolean:True</string>
- </value>
- </item>
- <item>
- <key>
- <string>olvApplications/Last updated:Width</string>
- </key>
- <value>
- <string>System.Int32:130</string>
- </value>
- </item>
- <item>
- <key>
- <string>olvApplications/Last updated:LastDisplayIndex</string>
- </key>
- <value>
- <string>System.Int32:-1</string>
- </value>
- </item>
- <item>
- <key>
- <string>olvApplications/Uses:Visibility</string>
- </key>
- <value>
- <string>System.Boolean:True</string>
- </value>
- </item>
- <item>
- <key>
- <string>olvApplications/Uses:Width</string>
- </key>
- <value>
- <string>System.Int32:40</string>
- </value>
- </item>
- <item>
- <key>
- <string>olvApplications/Uses:LastDisplayIndex</string>
- </key>
- <value>
- <string>System.Int32:-1</string>
- </value>
- </item>
- <item>
- <key>
- <string>olvApplications/LastSortColumn</string>
- </key>
- <value>
- <string>System.String:Application name</string>
- </value>
- </item>
- <item>
- <key>
- <string>olvApplications/LastSortOrder</string>
- </key>
- <value>
- <string>System.Int32:1</string>
- </value>
- </item>
- <item>
- <key>
- <string>ChooseAppsToInstallDialog/Size</string>
- </key>
- <value>
- <string>System.Drawing.Size:618,433</string>
- </value>
- </item>
- <item>
- <key>
- <string>ChooseAppsToInstallDialog/Location</string>
- </key>
- <value>
- <string>System.Drawing.Point:675,637</string>
- </value>
- </item>
- <item>
- <key>
- <string>ChooseAppsToInstallDialog/WindowState</string>
- </key>
- <value>
- <string>System.Int32:0</string>
- </value>
- </item>
- <item>
- <key>
- <string>olvApps/Name:Visibility</string>
- </key>
- <value>
- <string>System.Boolean:True</string>
- </value>
- </item>
- <item>
- <key>
- <string>olvApps/Name:Width</string>
- </key>
- <value>
- <string>System.Int32:263</string>
- </value>
- </item>
- <item>
- <key>
- <string>olvApps/Name:LastDisplayIndex</string>
- </key>
- <value>
- <string>System.Int32:-1</string>
- </value>
- </item>
- <item>
- <key>
- <string>olvApps/LastSortColumn</string>
- </key>
- <value>
- <string>System.String:Name</string>
- </value>
- </item>
- <item>
- <key>
- <string>olvApps/LastSortOrder</string>
- </key>
- <value>
- <string>System.Int32:1</string>
- </value>
- </item>
- <item>
- <key>
- <string>olvLists/Name:Visibility</string>
- </key>
- <value>
- <string>System.Boolean:True</string>
- </value>
- </item>
- <item>
- <key>
- <string>olvLists/Name:Width</string>
- </key>
- <value>
- <string>System.Int32:80</string>
- </value>
- </item>
- <item>
- <key>
- <string>olvLists/Name:LastDisplayIndex</string>
- </key>
- <value>
- <string>System.Int32:-1</string>
- </value>
- </item>
- <item>
- <key>
- <string>olvLists/Applications:Visibility</string>
- </key>
- <value>
- <string>System.Boolean:True</string>
- </value>
- </item>
- <item>
- <key>
- <string>olvLists/Applications:Width</string>
- </key>
- <value>
- <string>System.Int32:80</string>
- </value>
- </item>
- <item>
- <key>
- <string>olvLists/Applications:LastDisplayIndex</string>
- </key>
- <value>
- <string>System.Int32:-1</string>
- </value>
- </item>
- <item>
- <key>
- <string>olvLists/LastSortColumn</string>
- </key>
- <value>
- <string>System.String:Name</string>
- </value>
- </item>
- <item>
- <key>
- <string>olvLists/LastSortOrder</string>
- </key>
- <value>
- <string>System.Int32:0</string>
- </value>
- </item>
- <item>
- <key>
- <string>ChooseAppsToInstallDialog/ListsView</string>
- </key>
- <value>
- <string>System.Int32:4</string>
- </value>
- </item>
- <item>
- <key>
- <string>olvJobs/proto:Visibility</string>
- </key>
- <value>
- <string>System.Boolean:True</string>
- </value>
- </item>
- <item>
- <key>
- <string>olvJobs/proto:Width</string>
- </key>
- <value>
- <string>System.Int32:60</string>
- </value>
- </item>
- <item>
- <key>
- <string>olvJobs/proto:LastDisplayIndex</string>
- </key>
- <value>
- <string>System.Int32:11</string>
- </value>
- </item>
- <item>
- <key>
- <string>CopyFileInstructionDialog/Size</string>
- </key>
- <value>
- <string>System.Drawing.Size:402,163</string>
- </value>
- </item>
- <item>
- <key>
- <string>olvJobs/bytes:Visibility</string>
- </key>
- <value>
- <string>System.Boolean:True</string>
- </value>
- </item>
- <item>
- <key>
- <string>olvJobs/bytes:Width</string>
- </key>
- <value>
- <string>System.Int32:71</string>
- </value>
- </item>
- <item>
- <key>
- <string>olvJobs/bytes:LastDisplayIndex</string>
- </key>
- <value>
- <string>System.Int32:7</string>
- </value>
- </item>
- <item>
- <key>
- <string>olvJobs/hashExtVar:Visibility</string>
- </key>
- <value>
- <string>System.Boolean:True</string>
- </value>
- </item>
- <item>
- <key>
- <string>olvJobs/hashExtVar:Width</string>
- </key>
- <value>
- <string>System.Int32:60</string>
- </value>
- </item>
- <item>
- <key>
- <string>olvJobs/hashExtVar:LastDisplayIndex</string>
- </key>
- <value>
- <string>System.Int32:23</string>
- </value>
- </item>
- <item>
- <key>
- <string>olvJobs/hashInternal:Visibility</string>
- </key>
- <value>
- <string>System.Boolean:True</string>
- </value>
- </item>
- <item>
- <key>
- <string>olvJobs/hashInternal:Width</string>
- </key>
- <value>
- <string>System.Int32:60</string>
- </value>
- </item>
- <item>
- <key>
- <string>olvJobs/hashInternal:LastDisplayIndex</string>
- </key>
- <value>
- <string>System.Int32:19</string>
- </value>
- </item>
- <item>
- <key>
- <string>olvJobs/hashExternal:Visibility</string>
- </key>
- <value>
- <string>System.Boolean:True</string>
- </value>
- </item>
- <item>
- <key>
- <string>olvJobs/hashExternal:Width</string>
- </key>
- <value>
- <string>System.Int32:60</string>
- </value>
- </item>
- <item>
- <key>
- <string>olvJobs/hashExternal:LastDisplayIndex</string>
- </key>
- <value>
- <string>System.Int32:20</string>
- </value>
- </item>
- <item>
- <key>
- <string>olvJobs/checksum64:Visibility</string>
- </key>
- <value>
- <string>System.Boolean:True</string>
- </value>
- </item>
- <item>
- <key>
- <string>olvJobs/checksum64:Width</string>
- </key>
- <value>
- <string>System.Int32:33</string>
- </value>
- </item>
- <item>
- <key>
- <string>olvJobs/checksum64:LastDisplayIndex</string>
- </key>
- <value>
- <string>System.Int32:21</string>
- </value>
- </item>
- </dictionary>
- </Settings>
- <GlobalVariables>
- <Variable Name="7z" Content="7z.exe" />
- <Variable Name="saveDir" Content="c:\chocolatey-auto-save" />
- <Variable Name="autoPackagesFolder" Content="c:\code\chocolatey-packages\automatic" />
- <Variable Name="nopush" Content="--nopush" />
- <Variable Name="cscript" Content="2" />
- <Variable Name="null" Content="null" />
- <Variable Name="ie32" Content="Mozilla/4.0 (compatible; MSIE 8.0; Windows NT 6.1; Trident/4.0; SLCC2; .NET CLR 2.0.50727; .NET CLR 3.5.30729; .NET CLR 3.0.30729; Media Center PC 6.0; .NET4.0C)" />
- <Variable Name="ie64" Content="Mozilla/4.0 (compatible; MSIE 8.0; Windows NT 6.1; Win64; x64; Trident/4.0; .NET CLR 2.0.50727; SLCC2; .NET CLR 3.5.30729; .NET CLR 3.0.30729; Media Center PC 6.0; Media Center PC 5.0; SLCC1; Tablet PC 2.0; .NET4.0C)" />
- <Variable Name="firefox" Content="Mozilla/5.0 (Windows; U; Windows NT 6.1; en-US; rv:1.9.2.10) Gecko/20100914 Firefox/3.6.10" />
- <Variable Name="opera" Content="Opera/9.80 (Windows NT 6.1; U; en) Presto/2.6.30 Version/10.62" />
- <Variable Name="chrome" Content="Mozilla/5.0 (Windows; U; Windows NT 6.1; en-US) AppleWebKit/534.3 (KHTML, like Gecko) Chrome/6.0.472.63 Safari/534.3" />
- <Variable Name="wget" Content="wget/1.9+cvs-stable+(red+hat+modified)" />
- <Variable Name="curl" Content="pycurl/7.18.2" />
- <Variable Name="checksum" Content="{checksum}" />
- <Variable Name="checksumx64" Content="{checksumx64}" />
- <Variable Name="packageGuid" Content="{packageGuid}" />
- <Variable Name="url64" Content="{url64}" />
- <Variable Name="force" Content=" " />
- </GlobalVariables>
- <CodeSnippets>
- <Snippet Guid="7158800B-A188-4CAB-927C-31AA36FDD049" Name="chocopkgup" Type="1">chocopkgup {nopush} --packagename={appname} --version={version} --pg="{packageGuid}" --url="{preupdate-url}" --urlx64="{url64}" --packagepath="{file}" --checksum="{checksum}" --c64="{checksumx64}" --debug</Snippet>
- <Snippet Guid="BB8AF683-DA06-4C20-8434-9F854C46B961" Name="cs" Type="0">////////////////////////////////////////////////////////////////////////////////////////
- /// version 6.5
- ///
- /// FIX: do not re-push package if package already created
- ///
- // REQUIRES:
- // global vars: workdir=corresponds to download location of installer file
- // app vars: nopush, checksum64file=corresponds to 64 bit install file
- // file vars: same as specified by chocopkgup
- string varCScript = app.Variables.ReplaceAllInString("{cscript}");
- if ((varCScript == "1") || (varCScript == "2")) {
- string varAppname = app.Variables.ReplaceAllInString("{appname}");
- string varVersion = app.Variables.ReplaceAllInString("{version}");
- string varChocoPkgOutput = System.IO.Path.Combine(app.Variables.ReplaceAllInString("{autoPackagesFolder}"), "_output");
- string varChecksum = app.Variables.ReplaceAllInString("{checksum}");
- string varChecksumx64 = app.Variables.ReplaceAllInString("{checksumx64}");
- string varChecksum64File = app.Variables.ReplaceAllInString("{checksum64file}");
- string varChecksum64basefile = app.Variables.ReplaceAllInString("{checksum64file:basefile}");
- string varChecksum64ext = app.Variables.ReplaceAllInString("{checksum64file:ext}");
- string varWorkdir = app.Variables.ReplaceAllInString("{workdir}");
- string saveFileName64 = String.Concat(varChecksum64basefile, ".", varChecksum64ext);
- // equivalent to ketarin variable "{file}"
- //string savePath = app.PreviousLocation;
- string savePath = app.PreviousLocation;
- string pkgPath = Path.Combine(varChocoPkgOutput, varAppname, varVersion);
- if (!System.IO.Directory.Exists(pkgPath)) {
- pkgPath = Path.Combine(varChocoPkgOutput, varAppname);
- }
- string fileNameNuspec = String.Concat(varAppname, ".nuspec");
- string fileUriNuspec = Path.Combine(pkgPath, fileNameNuspec);
- string fileNameNupkg = String.Concat(varAppname, ".", varVersion, ".nupkg");
- string fileUriNupkg = Path.Combine(pkgPath, fileNameNupkg);
- // do not re-push package if package already created
- DateTime today = DateTime.Today;
- DateTime pkgCreateDate = File.GetCreationTime(pkgPath);
- if (today > pkgCreateDate) {
- return;
- }
- if (varChecksum == "{checksum}") {
- // calculate SHA1
- System.IO.FileStream fileSha1 = new System.IO.FileStream(savePath, System.IO.FileMode.Open);
- System.Security.Cryptography.SHA1 sha1 = new System.Security.Cryptography.SHA1CryptoServiceProvider();
- byte[] retValSha1 = sha1.ComputeHash(fileSha1);
- fileSha1.Close();
- // create a string
- System.Text.StringBuilder sbSha1 = new System.Text.StringBuilder();
- for (int i = 0; i < retValSha1.Length; i++) {
- sbSha1.Append(retValSha1[i].ToString("x2"));
- }
- string replaceChecksum = sbSha1.ToString();
- List<string> fileList = new List<string>(Directory.GetFiles(pkgPath, "*.ps1", SearchOption.AllDirectories));
- string[] filesNuspec = Directory.GetFiles(pkgPath, "*.nuspec", SearchOption.AllDirectories);
- fileList.AddRange(filesNuspec);
- string[] files = fileList.ToArray();
- foreach (string file in files) {
- try {
- string contents = File.ReadAllText(file);
- contents = contents.Replace("{checksum}", replaceChecksum);
- // Make files writable
- // File.SetAttributes(file, FileAttributes.Normal);
- File.WriteAllText(file, contents);
- } catch (Exception ex) {
- Console.WriteLine(ex.Message);
- }
- }
- }
- // only get checksum if {checksum64file} exists and points to a downloadable file
- if (varChecksumx64 == "{checksumx64}" && varChecksum64File != "{checksum64file}") {
- string savePath64 = Path.Combine(varWorkdir, saveFileName64);
- System.Net.WebClient webClient = new System.Net.WebClient();
- webClient.DownloadFile(varChecksum64File, savePath64);
- // calculate SHA1
- System.IO.FileStream file64Sha1 = new System.IO.FileStream(savePath64, System.IO.FileMode.Open);
- System.Security.Cryptography.SHA1 sha164 = new System.Security.Cryptography.SHA1CryptoServiceProvider();
- byte[] retVal64Sha1 = sha164.ComputeHash(file64Sha1);
- file64Sha1.Close();
- // create a string
- System.Text.StringBuilder sb64Sha1 = new System.Text.StringBuilder();
- for (int i = 0; i < retVal64Sha1.Length; i++) {
- sb64Sha1.Append(retVal64Sha1[i].ToString("x2"));
- }
- string replace64Checksum = sb64Sha1.ToString();
- List<string> fileList = new List<string>(Directory.GetFiles(pkgPath, "*.ps1", SearchOption.AllDirectories));
- string[] filesNuspec = Directory.GetFiles(pkgPath, "*.nuspec", SearchOption.AllDirectories);
- fileList.AddRange(filesNuspec);
- string[] files = fileList.ToArray();
- foreach (string file in files) {
- try {
- string contents = File.ReadAllText(file);
- contents = contents.Replace("{checksumx64}", replace64Checksum);
- File.WriteAllText(file, contents);
- } catch (Exception ex) {
- Console.WriteLine(ex.Message);
- }
- }
- }
- int checkBeta = varVersion.Split('-').Length;
- if ( checkBeta == 2) {
- string strPre = varVersion.Split('-')[1];
- string strReplace = String.Concat(strPre, "</version>");
- string strCheck = String.Concat(".", DateTime.Now.ToString("yyyyMMdd"), "</version>");
- string[] fileNuspec = Directory.GetFiles(pkgPath, "*.nuspec", SearchOption.AllDirectories);
- foreach (string file in fileNuspec) {
- string contents = File.ReadAllText(file);
- contents = contents.Replace(strCheck, strReplace);
- File.WriteAllText(file, contents);
- }
- }
- // delete existing nupkg made by chocopkgup; we leverage chocopkgup to create the structure/files in destination
- System.Diagnostics.Process process1 = new System.Diagnostics.Process();
- System.Diagnostics.ProcessStartInfo proc1 = new System.Diagnostics.ProcessStartInfo();
- proc1.WindowStyle = System.Diagnostics.ProcessWindowStyle.Hidden;
- proc1.UseShellExecute = true;
- proc1.WorkingDirectory = pkgPath;
- proc1.FileName = "cmd.exe";
- proc1.Arguments = "/c "+"del /f " + fileUriNupkg;
- process1.StartInfo = proc1;
- process1.Start();
- // create a new nupkg
- System.Diagnostics.Process process2 = new System.Diagnostics.Process();
- System.Diagnostics.ProcessStartInfo proc2 = new System.Diagnostics.ProcessStartInfo();
- proc2.WindowStyle = System.Diagnostics.ProcessWindowStyle.Hidden;
- proc2.UseShellExecute = true;
- proc2.WorkingDirectory = pkgPath;
- proc2.FileName = "cmd.exe";
- proc2.Arguments = "/c "+"choco pack "+fileUriNuspec+" -d";
- process2.StartInfo = proc2;
- process2.Start();
- // push the nupkg
- if (varCScript == "2") {
- System.Diagnostics.Process process3 = new System.Diagnostics.Process();
- System.Diagnostics.ProcessStartInfo proc3 = new System.Diagnostics.ProcessStartInfo();
- proc3.WindowStyle = System.Diagnostics.ProcessWindowStyle.Hidden;
- proc3.UseShellExecute = true;
- proc3.WorkingDirectory = pkgPath;
- proc3.FileName = "cmd.exe";
- // find nupkg in pkgPath
- string[] pushPkg = Directory.GetFiles(pkgPath, "*.nupkg", SearchOption.TopDirectoryOnly);
- foreach (String file in pushPkg) {
- proc3.Arguments = "/c "+"cpush " + file + " -d";
- }
- process3.StartInfo = proc3;
- System.Threading.Thread.Sleep(2000);
- process3.Start();
- }
- }</Snippet>
- </CodeSnippets>
- <SetupLists />
- </Ketarin>
|