Open forki opened 6 years ago
Example PR for magic mode: https://github.com/SAFE-Stack/SAFE-BookStore/pull/300
Example PR for old school mode: https://github.com/fsprojects/Argu/pull/104/files
Note: in both cases we add the 63KB paket.bootstrapper.exe to the project - just target file names differ.
@shiftkey offered help. I would appreciate that very much
I've noticed that quite a few of these are forks - do we want to open PRs on the mainline repos only or also on all the forks?
When sending PR, don't forget to add "I'm some random person on the internet. To check that I'm not adding any malicious code into your codebase, refer to official Paket repository with pubished SHA256 checksum and, please, validate that it is matching."
@cdrnet Yes that was my next message on the slack, Github API (via Octokit?) should be queried for each to get if it's a fork, get the size to ensure that it's not the main paket and download it to check the version
@eugene-g yes good point. The text message should be good and also include security notice. And we should send it from a trusted account.
Ok I computed the repos that would need an upgrade : https://docs.google.com/spreadsheets/d/1cjmf7YD-3ZnPzJxNIPl_6m0YS2dFYf45kdUF3ZJ-yYU/edit?usp=sharing
That is the previous list where I queried if they were forks and the version of the bootstrapper to check that it wasn't the latest
open FSharp.Control.Tasks
open Octokit
open Octokit.Helpers
open Octokit.Internal
let repos =
[|
"fsprojects/FSharp.Configuration";"15below/Ensconce";"gigya/microdot";"BlythMeister/Gallifrey";"fsprojects/FSharpLint";"jgrund/fable-jest";"vik-borisov/TelegramClient";"delegateas/XrmMockup";"SAFE-Stack/SAFE-BookStore";"fsprojects/Paket";"CSBiology/BioFSharp";"ionide/ionide-vscode-fsharp";"fable-compiler/Fable";"fsprojects/matprovider";"fwaris/CALib";"Thorium/Owin.Compression";"JohanLarsson/Gu.Reactive";"red-gate/RedGate.Build";"WebApiContrib/WebAPIContrib.Core";"elastic/elasticsearch-net";"mennowo/TLCGen";"yurii-litvinov/REAL.NET";"CSBiology/FSharp.Stats";"janno-p/XRoadLib";"krauthaufen/FShade";"hafuu/FSharpApiSearch";"SayToMe/Solve";"gusty/FSharpPlus";"fsdn-projects/FSDN";"vbfox/stidgen";"NinetailLabs/VaraniumSharp.Initiator";"NinetailLabs/VaraniumSharp";"punker76/code-samples";"fslaborg/XPlot";"ReedCopsey/Gjallarhorn";"nhsevidence/ld-bnf";"TheAngryByrd/MiniScaffold";"KevM/tikaondotnet";"fsprojects/FSharp.CloudAgent";"fluentribbon/Fluent.Ribbon";"aardvark-platform/aardvark.rendering";"fsprojects/FSharp.TypeProviders.SDK";"lefthandedgoat/canopyStarterKit";"JohanLarsson/Gu.Wpf.DataGrid2D";"mennowo/Gu.Wpf.DataGrid2D";"stefanmaierhofer/Uncodium.Units";"madhon/lighthouse";"aabenoja/Cake.Parallel";"MangelMaxime/Fulma";"JohanLarsson/Gu.State";"ionide/ionide-vscode-helpers";"colinbull/colinbull.github.io";"jet/kafunk";"fsprojects/FSharp.AWS.DynamoDB";"PaulStovell/ServiceBouncer";"eiriktsarpalis/TypeShape";"CSBiology/FSharp.Care";"fsprojects/FSharp.Data.TypeProviders";"enovales/LudumLinguarum";"JasperFx/alba";"fable-compiler/fable-react";"nozzlegear/davenport.net";"inosik/Fable";"ncave/Fable";"intellifactory/websharper";"y2k/JoyReactorRN";"steego/Steego.Demo";"lefthandedgoat/canopy";"nessos/Argu";"fsprojects/Argu";"NinetailLabs/NeuroLinker";"JohanLarsson/Gu.Analyzers";"pingthepeople/ptp-functions";"jhoerr/iga-tracker-functions";"intellifactory/websharper.ui.next";"wastaz/Hyperboliq";"muehlhaus/FSharp.Plotly";"pbbwfc/Lizard";"intellifactory/websharper.owin";"intellifactory/websharper.forms";"intellifactory/websharper.ui.next.piglets";"intellifactory/websharper.html";"sergey-tihon/OpenNLP.NET";"nessos/FsPickler";"mbraceproject/FsPickler";"ionide/ionide-vscode-paket";"fsharp/FsCheck";"fscheck/FsCheck";"OpenTl/OpenTl.Schema";"johnberzy-bazinga/FSharp.Data.GraphQL";"bazingatechnologies/FSharp.Data.GraphQL";"fslaborg/FSharp.Charting";"Antaris/RazorEngine";"phatcher/CsvReader";"haf/expecto";"punker76/Fluent.Ribbon";"fluentribbon/XamlCombine";"eacasanovaspedre/functional-data-structures";"fsprojects/IfSharp";"fable-compiler/fable-suave-scaffold";"draganjovanovic1/terminal-snake";"intellifactory/websharper.o3d";"intellifactory/websharper.leaflet";"intellifactory/websharper.glmatrix";"intellifactory/websharper.bing.maps";"intellifactory/websharper.d3";"intellifactory/websharper.charting";"mvno/Okanshi";"bjornna/dips-ckm";"intellifactory/websharper.forms.bootstrap";"F-2-F/F2F.ReactiveNavigation";"phatcher/NCheck";"kerams/Templatus";"fsprojects/SwaggerProvider";"Horusiath/Akkling";"phatcher/SpecFlow.Unity";"TIHan/Foom";"fsharp/FsAutoComplete";"baronfel/Paket";"CSBiology/BioFSharp.Mz";"getgauge/gauge-csharp";"YaccConstructor/YaccConstructor";"niklaslundberg/Arbor.X";"gmpl/FSharpPlus";"delegateas/XrmDefinitelyTyped";"Zaid-Ajaj/LiteDB.FSharp";"sergey-tihon/Stanford.NLP.NET";"sqc1999/LxRunOffline";"nozzlegear/alexa-skills";"the-gamma/gallery-csv-service";"the-gamma/thegamma-script";"xiaoyvr/SimpleHttpMock";"vrvis/aardvark.base";"fsharp-editing/Forge";"ai-traders/liget";"fsprojects/FSharp.TypeProviders.StarterPack";"RFQ-hub/SocketIoSuave";"DigitalFlow/Xrm-Update-Context";"fsprojects/FsXaml";"readysetmark/WealthPulse";"Hosch250/Checkers";"isaksky/FsSqlDom";"delegateas/Delegate.XrmDefinitelyTyped";"JohanLarsson/Gu.Wpf.UiAutomation";"JohanLarsson/Gu.Roslyn.Asserts";"BillHally/FSharp.Chart";"nessos/UnionArgParser";"JohanLarsson/Gu.Wpf.ValidationScope";"JohanLarsson/Gu.Wpf.ToolTips";"JohanLarsson/Gu.Wpf.PropertyGrid";"JohanLarsson/Gu.Wpf.NumericInput";"JohanLarsson/Gu.Wpf.Media";"JohanLarsson/Gu.Wpf.Geometry";"JohanLarsson/Gu.Wpf.FlipView";"JohanLarsson/Gu.Localization";"JohanLarsson/Gu.Wpf.Adorners";"fsprojects/FSharp.Control.AsyncSeq";"chinwobble/DaisyParser";"julienadam/AttachR";"Thorium/Linq.Expression.Optimizer";"dungpa/fantomas";"mathnet/mathnet-symbolics";"OrleansContrib/Orleankka";"JohanLarsson/Gu.ChangeTracking";"JohanLarsson/Gu.Persist";"JohanLarsson/Gu.Settings";"DotNetAnalyzers/WpfAnalyzers";"vrvis/aardvark";"Creuna-Oslo/Episerver.Basis.Slim";"janno-p/XRoadProvider";"tpetricek/FSharp.Formatting";"jackfoxy/FSharp.Formatting";"wikibus/Argolis";"daniel-chambers/FSharp.Azure.Storage";"fsprojects/FSharp.Azure";"fsprojects/FSharp.Azure.Storage";"fsprojects/ProjectScaffold";"AmyrisInc/GslCore";"cloudRoutine/Paket";"tytusse/GitVersionTypeProvider";"mennowo/MiniTD";"cloudRoutine/FSharp.Formatting";"AlaricDelany/Schwefel.Ruthenium";"BayardRock/IfSharp";"persimmon-projects/Persimmon";"pdfforge/translatable";"fsprojects/Paket.VisualStudio";"vbfox/Paket";"questnet/FSCS-Lensgenerator";"embix/FSCS-Lensgenerator";"RMCKirby/ColorConsole";"dsyme/FSharp.TypeProviders.StarterPack";"JohanLarsson/Gu.Inject";"aardvarkplatform/aardvark.docs";"kichristensen/InfluxDB.WriteOnly";"mastoj/kalender2015";"teo-tsirpanis/FsRandom-pcg";"EveResearchFoundation/EveGameEngine";"callmekohei/deopletefs";"tpluscode/UriTemplateString";"pocketberserker/Data.HList";"TheAngryByrd/Marten.FSharp";"vrvis/aardvark.rendering";"erbg/HRON";"persimmon-projects/Persimmon.MuscleAssert";"sergey-tihon/FSharp.TypeProviders.StarterPack";"fjoppe/Legivel";"fjoppe/FsYamlParser";"JohanLarsson/Gu.Units";"muehlhaus/BioFSharp";"hoonzis/Pricer";"persimmon-projects/Persimmon.Script";"jorgef/fsharpworkshop";"madhon/statsd.net";"madhon/ostrich";"rflechner/Suave.Swagger";"sideeffffect/FSharpx.Collections";"95ulisse/FsCPS";"vreniose95/Ccr";"reflash/chat-backend";"VasiliskDevelopment/CardboardFactorySolution";"smolyakoff/conreign";"sergey-tihon/SwaggerProvider";"mattstermiller/koffee";"giacomociti/FSharp.Data.Xsd";"unic/bob-keith";"jkone27/AliceMQ";"demystifyfp/FsTweet";"sillyotter/BackupDBToAzure";"theimowski/SuaveMusicStore";"YaccConstructor/Brahma.FSharp";"fsprojects/AzureStorageTypeProvider";"arthis/glomulish";"rflechner/LinqToSalesforce";"0x53A/Paket";"thinkbeforecoding/Paket";"dady8889/Fluent.Ribbon";"RFQ-hub/ZabbixAgentLib";"janno-p/fable-vue";"whitetigle/samples-pixi";"mbraceproject/MBrace.Azure";"AmyrisInc/Gslc";"WalternativE/fableshotdetection";"ionide/ionide-fsgrammar";"hanswolff/dedilib";"cloudRoutine/FAKE";"jjpatel/pushtray";"mbraceproject/MBrace.Core";"teo-tsirpanis/Farkle";"ivaylo5ev/mason";"YaccConstructor/Examples";"e-rik/XRoadLib";"phatcher/Meerkat.Security.Hmac";"rflechner/FSharp.Data";"codehutch/pg3d";"nu-soft/FSharp.Plc.Ads";"CaringDev/FsUnit.xUnit.Typed";"boumenot/Wapiti.NET";"Jallah/Connect4Challenge";"HLWeil/BioFSharp";"fsprojects/Canopy.Mobile";"ed-ilyin/FSharp.EdIlyin.Core";"mbraceproject/MBrace.AWS";"also-cloud/AlsoCloud.Marketplace";"VaseninaAnna/Brahma.FSharp";"danieljsummers/FromObjectsToFunctions";"pkese/Orleankka";"ShalamovRoman/YC.Web";"bvenn/BioFSharp";"editorconfig/editorconfig-visualstudio";"FSharp-CN/FSharpBB";"baronfel/FAKE";"migfig/Labs";"ExM/NMoney";"ar3cka/Journalist";"mbraceproject/Vagabond";"nessos/Vagabond";"ExM/NConfiguration";"cgravill/TypesTSFS";"delegateas/Delegate.XrmContext";"nessos/Thespian";"ncave/fable-repl";"steego/toychest";"datNET/fs-fake-targets";"DigitalFlow/Xrm-Oss-Interfacing";"corux/seafile-cli-windows";"popular-parallel-programming/quad-ropes";"pocketberserker/FSDN";"fable-compiler/samples";"vbfox/FAKE";"MiloszKrajewski/FAKE";"yodiz/HttpApp";"ploeh/FsCheck";"MatrixSolutions/FSharp.Data.JsonValidation";"jeremyabbott/Presentations";"lefthandedgoat/openfsharpdemo";"pblasucci/quickpbt";"mleech/scotch";"GraanJonlo/MiniScaffold";"Dzoukr/Fue";"mhertis/Orleankka";"UgurAldanmaz/ServiceBouncer";"Lleutch/Sast";"leleutch/GenerativeTypeProviderExample";"amazingant/Amazingant.FSharp.TypeExpansion.Templates";"NinetailLabs/VaraniumSharp.Monolith";"LambdaFactory/fable-vscode-demo";"nhsevidence/ld-viewer";"nhsevidence/ld-qs-viewer";"sideeffffect/FSharpx.Extras";"elic-io/Hello.World";"fsprojects/FSharp.Data.Toolbox";"vrvis/fablish";"OlegZee/Xake";"cagyirey/Capstone.FSharp";"TheAngryByrd/Fable.Template.Library";"ElijahReva/ticket-problem";"awright18/SimpleExcelExporter";"sergey-tihon/Paket";"Cubey2019/Fluent.Ribbon";"teo-tsirpanis/expecto";"kMutagene/BioFSharp";"artur-s/Paket";"matthid/Yaaf.FSharp.Scripting";"haraldsteinlechner/FsPickler";"barsgroup/linq2db";"barsgroup/bars2db";"Spreads/Spreads.R";"lukasimir/SimJobShop1";"jeroldhaas/Gjallarhorn";"theprash/AzureStorageTypeProvider";"varon/FSLogger";"TOTBWF/FSharp.Data.GraphQL";"hodzanassredin/NFastText";"fsprojects/ExcelProvider";"CSBiology/FSharp.FGL";"irustandi/ReinforcementLearningFSharp";"BayardRock/Fungible";"blair55/canopy";"TeaDrivenDev/Amagatsha";"TeaDrivenDev/BranchDocuments";"cloudRoutine/FsAutoComplete";"nicolocodev/suavegnalr";"DingpingZhang/MaterialDesignInXamlToolkit";"TahaHachana/XPlot";"relayfoods/FsToolkit";"MattiasJakobsson/SuperGlue";"SuperGlueFx/SuperGlue";"fsprojects/projekt";"johnazariah/roslyn-wrapper";"andburn/hs-art-extractor";"mattj23/mathnet-spatial";"ArtofQuality/F2F.ReactiveNavigation";"sideeffffect/ProjectScaffold";"aolney/braintrust-server";"robertmuehsig/Fluent.Ribbon";"lexarchik/Paket";"Amyris/AmyrisBio";"Rickasaurus/Barb";"toburger/FSharp.Json";"divad4686/places-google-details";"15below/Sproc.Lock";"andredublin/Forge";"cryosharp/fluentwindsor";"JohnStov/Frobnicator2";"hoonzis/fluentnest";"CSGOpenSource/elasticsearch-net";"NUIM-BCL/DiffSharp";"DiffSharp/DiffSharp";"gilles-leblanc/genesis";"tjaskula/akka.net-fsharp.extensions";"ploeh/PollingConsumer";"Steinpilz/confifu-commands";"pittsw/TheWanderer";"eriove/mathnet-numerics";"ChipmunkHand/GiraffeRescue";"wooga/Paket.Unity3D";"ed-ilyin/EdIlyin.FSharp.Elm.Core";"daz10000/fss";"pkanavos/FakeCake_DNZ";"fsprojects/ExcelFinancialFunctions";"vilinski/MongoDB.Bson.FSharp";"pirrmann/FSketch";"johnazariah/csharp-algebraictypes";"johnazariah/csharp-uniontypes";"fsprojects/FSharp.Management";"RinsibleElk/TextOn.Atom";"contactsamie/FinCa";"miklund/inquiry";"Stift/Paket";"CSBiology/FSharpGephiStreamer";"fslaborg/RProvider";"fsprojects/FSharp.Compiler.CodeDom";"fsprojects/FSharpx.Collections";"ksmirenko/Brahma.FSharp";"TeaDrivenDev/StatusPotentiae";"fsharp-editing/fstoml";"fsprojects/FsLexYacc";"Hopac/Hopac";"cotyar/Akkling";"johanclasson/Unity.Interception.Serilog";"npmurphy/IfSharp";"scottgrey/weather";"the-gamma/govuk-data-import";"spr13/ACWES";"rneatherway/FsAutoComplete";"bullmastiffo/Contour";"josselinauguste/exim-maillog";"mandest/FSFabric";"mseknibilel/Alfred";"dsyme/MBrace.Azure";"dsyme/MBrace.Core";"adelnizamutdinov/music-page";"dsyme/FSharp.Charting";"madhon/Formo";"tipunch74/MaterialDesignInXamlToolkit";"eerohele/oath";"TheInnerLight/Nomad";"sfukui/MNNPlus";"sideeffffect/FinFun.Contracts";"boloutaredoubeni/kaleidoscope";"mhtraylor/market-sim";"Slesa/Dotter";"dkholod/GoogleCloudChaosMonkey";"cagyirey/Shodan.FSharp";"mastoj/BigQueryProvider";"caindy/ODataTypeProvider";"csjune/mathnet-spatial";"mathnet/mathnet-filtering";"skalinets/eat-now";"mandest/Nap";"colinbull/SqlProvider";"VerbalExpressions/FSharpVerbalExpressions";"enovales/feltlion";"kellerd/TicTacToeProvider";"stewart-r/AzureDocumentDbTypeProvider";"pkanavos/CSharpRevolution_DNZ";"mvno/Franz";"TheInnerLight/CSharp.Formatting";"Thilas/commandline";"pittsw/Indy.NET";"persimmon-projects/Persimmon.Unquote";"giacomociti/AntaniXml";"teo-tsirpanis/brainsharp";"sergey-tihon/FSharp.Management";"Steinpilz/confifu";"sergey-tihon/FSharp.Compiler.Service";"fsharp/xamarin-monodevelop-fsharp-addin";"danm-de/Fractions";"beeker/FAKE";"mavnn/Taggen";"FsStorm/FsStorm";"bennylynch/SQLProvider";"tgrospic/advent-of-code";"mzabolotko/Contour";"SDVentures/Contour";"Badmoonz/FSharp.ReportDSL";"fsharp-editing/FSharp.Editing";"FSharpBristol/FSharpBristolPresentations";"jmquigs/ModelMod";"cloudRoutine/toml-fs";"matthid/Yaaf.AdvancedBuilding";"carbon-twelve/Akabeko";"CumpsD/knx.net";"sidburn/sidburn.github.io";"vossccp/BotBuilderChannelConnector";"0x53A/FSharp.Compiler.Service";"snowcrazed/Paket";"figrollapps/PersonalTrainer";"pocketberserker/FSharp.Object.Diff";"robertpi/caffe.clr.demo";"rackspace/rackspace-net-sdk";"alfonsogarciacaro/FSharp.Compiler.Service";"forki/FSharp.Compiler.Service";"xavierzwirtz/FSharp.QueryProvider";"voiceofwisdom/FSharp.QueryProvider";"zeromq/fszmq";"pblasucci/fszmq";"jbeeko/TypeUp";"object/MidiFsharp";"cosmo0920/grnline.fs";"rfrerebe/fable-suave-scaffold";"adam-mccoy/elasticsearch-net";"Thorium/Paket";"rflechner/SlackTypeProvider";"pocketberserker/ZeroFormatter.FSharpExtensions";"simonhdickson/Paket";"soerennielsen/canopy";"imazen/libwebp-net";"tpetricek/Deedle";"czifro-tech/30-days-of-fsharp";"AITGmbH/ApplyCompanyPolicy.Template";"AITGmbH/AIT-Apply-Company-Policy-SDK";"dolly22/FAKE.Dotnet";"alexeyzimarev/MassTransit.RavenDbIntegration";"et1975/fable-suave-scaffold";"mjul/aws-lambda-fsharp-lab";"wallymathieu/SemVer.FromAssembly";"mvkra/WebsocketFrameworkTester";"vain0/EnumerableTest";"ScottShingler/FsStorm";"dangets/ionide-atom-fsharp";"ionide/ionide-atom-fsharp";"ionide/ionide-fsharp";"fbehrens/vscode-polyglott";"fsharping/Website";"msdyncrm-contrib/PluginAssemblyLoader";"ionide/ionide-vscode-fake";"jeremyabbott/doctoralsurvey";"ijsgaus/fun";"rexcfnghk/marksix-parser";"rojepp/FSharp.Compiler.Service";"fradav/IfSharp";"deapsquatter/FSharp.SSEClient";"alexpantyukhin/FSharp.Data.GraphQL";"fsprojects/FSharp.ViewModule";"pocketberserker/ComVu";"mjul/dropbox-activity-reports";"TIHan/Ferop";"opcon/turnt-ninja";"inosik/Paket";"arthis/psychic-tribble";"davidpodhola/fable-suave-scaffold";"amazingant/Amazingant.FSharp.TypeExpansion";"TomGillen/GoldenHammer";"TheInnerLight/FSPipes";"bchavez/Dwolla";"ksmirenko/type-providers";"jindraivanek/fueBlog";"HackYourJob/hexagonchallenge";"Graph-Parsing-Demo-Group/YC.GraphParsingDemo";"Bio-graph-group/YC.BioGraph";"mjul/fslab-playground";"KochetovKirill/YC.GraphParsingDemo";"ZachBray/FunScript";"vbfox/U2FExperiments";"kate-paulk/tae_exam_candidate_kp";"statmuse/TokensRegexProvider";"kuroyakov/fsharp-study";"wikibus/Rdf.Vocabularies";"eugene-g/ambiata-weather";"rexcfnghk/FSharp.Backup";"cloudRoutine/VisualFSharpPowerTools";"fsprojects/VisualFSharpPowerTools";"kjnilsson/FSharp.AutoComplete";"ionide/ionide-fsi";"ionide/ionide-helpers";"jmjrawlings/SpannerFS";"BlythMeister/BingImageDowload";"frankshearar/etwas";"Giusy151/mathnet-spatial";"xdaDaveShaw/FSharp-Suave-Expecto";"lefthandedgoat/genit";"Bomret/Unit";"cloudRoutine/Forge";"isaacabraham/Paket";"MnZrK/fundcpp";"MnZrK/fdcpp";"fsprojects/FSharpx.Extras";"Bomret/NeverNull";"theor/GitShow";"smkell/fsfbl";"the-gamma/thegamma-olympics-web";"DIPSASA/dips-ckm";"fsprojects/FSharpx.Async";"NinetailLabs/Cake.PaketRestore";"mathias-brandewinder/wonderland-fsharp-katas";"endeavour/PerfectShuffle.WebsharperExtensions";"hsharpsoftware/use-case-maker";"pmbanka/kkm-reminder";"hmemcpy/Paket.VisualStudio";"enovales/FsGettextUtils";"bartelink/FunDomain";"john-patterson/FSharp.Desktop.UI";"wikibus/JsonLD.Entities";"persimmon-projects/Persimmon.Dried";"sylvanc/CamdenTown";"TheAngryByrd/OWASPPipelineSlides";"SDVentures/HostBox";"mfwilson/myriad";"larzw/Cake.Paket.Example";"OlegZee/Suave.OAuth";"endeavour/PerfectShuffle.Security";"nhsevidence/ld-compiler";"blainne/RightHandOfFate";"gjuljo/HelloSuave";"willryan/MemoryWaybackAPI";"FoothillSolutions/FunctionalEconnect";"enerqi/AlgorithmPad";"JeremyBellows/NeuralFish"
|]
let getBootstrapperInTree (tree: TreeItem seq) =
tree |> Seq.filter(fun item ->
(item.Type.Value = TreeType.Blob)
&& (item.Size < 100 * 1024)
&& (item.Path = "paket.exe"
|| item.Path = "paket.bootstrapper.exe"))
|> List.ofSeq
let getDotPaketInTree (tree: TreeItem seq) =
tree |> Seq.tryFind(fun item ->
(item.Type.Value = TreeType.Tree)
&& (item.Path = ".paket"))
let getBootstrapper owner name reference (client: GitHubClient) = task {
let! (treeResponse: TreeResponse) = client.Git.Tree.Get(owner, name, "heads/" + reference)
let direct = getBootstrapperInTree treeResponse.Tree |> List.map(fun x -> x.Path, x)
match getDotPaketInTree treeResponse.Tree with
| Some dotPaket ->
let! (dotPaketTreeResponse: TreeResponse) = client.Git.Tree.Get(owner, name, dotPaket.Sha)
let inDotPaket = getBootstrapperInTree dotPaketTreeResponse.Tree
return direct @ (inDotPaket |> List.map(fun x -> ".paket/" + x.Path, x))
| None -> return direct
}
let limit = Version("5.142.0")
let cred = new Credentials((*shhh*))
use github = new GitHubClient(new ProductHeaderValue("old-paket-finder"), InMemoryCredentialStore(cred));
(task {
for repo in repos do
let parts = repo.Split('/')
let user = parts.[0]
let repoName = parts.[1]
let! (repo: Repository) = github.Repository.Get(user, repoName)
if repo.Fork = false then
let defaultBranch = repo.DefaultBranch
let! bootstrappersFound = getBootstrapper user repoName defaultBranch github
if bootstrappersFound.Length > 0 then
let (path, treeItem) = bootstrappersFound.Head
let! (blob: Blob) = github.Git.Blob.Get(user, repoName, treeItem.Sha)
let fileBytes = Convert.FromBase64String(blob.Content)
File.WriteAllBytes(@"C:\temp\paket_temp.exe", fileBytes)
let verInfo = FileVersionInfo.GetVersionInfo(@"C:\temp\paket_temp.exe")
let v = Version(verInfo.FileVersion)
if v < limit then
printfn "%s,%s,%s,%s" user repoName path (verInfo.FileVersion)
}).Wait();
I just checked the list to see which of my repositories came up, and I think the query may be a bit off.
For example https://github.com/TeaDrivenDev/BranchDocuments doesn't exist anymore and has been renamed to https://github.com/TeaDrivenDev/Amagatsha (which is also listed).
And https://github.com/TeaDrivenDev/GjallarhornTest2 is missing, although it has a 5.132 bootstrapper (weirdly as both paket.exe
and paket.bootstrapper.exe
).
@forki I've put together a rough script to do all this over in https://github.com/shiftkey/paket-upgrader, and you can see it in action here: https://github.com/TeaDrivenDev/StatusPotentiae/pull/1
@forki @TeaDrivenDev and others - I'm looking for feedback on how to simplify this so others can use it and share the load, mostly around a proper CLI so that you could pass in a list of repositories or just point it at someone's account.
Also, I want to make sure that these PRs do resolve the problem before broadcasting this more broadly...
@shiftkey Works for me. I deleted the 5.142 .exe from AppData\Local\NuGet\Cache\Paket
, ran the "magic mode" bootstrapper on master
and got the TLS error. Bootstrapper on the PR branch correctly downloads Paket 5.142.
Yes that was my next message on the slack, Github API (via Octokit?) should be queried for each to get if it's a fork, get the size to ensure that it's not the main paket and download it to check the version
@vbfox I'd recommend using the Content API to check the SHA of the paket.exe
or paket.bootstrapper.exe
rather than rely on the file size:
And the work to create a new commit through the GitHub API (avoiding the need to clone it locally) is here:
Apologies for the C#, but it was quicker for me to bash something together 😈
cool stuff. After small test I tried to run it on repositories.txt but two things:
a) everything in parallel seems to be an issue b) I assume it hit rate limit ---> no pull request created
@vbfox created the following statement
"1524 projects have files that are either paket or it's bootstrapper in standard positions https://docs.google.com/spreadsheets/d/19Th3rRWBIoFxlBpbuDQ9QSd7tlJ05Fibq7VFH9h52mE/edit#gid=1315769600 Of theses 590 had commits after 2017-01-01: https://docs.google.com/spreadsheets/d/1m6Qu_lEy1LQYKoBpKA9HVMvMvIRQj70mdf1pfaA3S0A/edit#gid=63915918
Thanks google bigquery :slightly_smiling_face: Family time now but if someone wants to auto-create PRs it's a start."
So all these projects need the patch in https://github.com/fsprojects/Paket/pull/3066
What we need to do:
For each of the repos we need to replace the bootstrapper with 5.142
If the repo uses it as paket.bootstrapper.exe then we just need to replace it. If they have a paket.exe then we copy paket.bootstrapper.exe over their existing paket.exe and call it paket.exe (magic mode)