{"action":"created","comment":{"url":"https://api.github.com/repos/dotnet/cli/pulls/comments/66668420","id":66668420,"diff_hunk":"@@ -0,0 +1,57 @@\n+﻿// Copyright (c) .NET Foundation and contributors. All rights reserved.\n+// Licensed under the MIT license. See LICENSE file in the project root for full license information.\n+\n+using System.IO;\n+using Microsoft.DotNet.Cli.Utils;\n+using Microsoft.Extensions.EnvironmentAbstractions;\n+using Microsoft.DotNet.ProjectModel.Resolution;\n+\n+namespace Microsoft.DotNet.Configurer\n+{\n+    public class NuGetCacheSentinel : INuGetCacheSentinel\n+    {\n+        public static readonly string SENTINEL = $\"{Product.Version}.dotnetSentinel\";\n+\n+        private readonly IFile _file;\n+\n+        private string _nugetCachePath;\n+\n+        private string NuGetCachePath\n+        {\n+            get\n+            {\n+                if (string.IsNullOrEmpty(_nugetCachePath))\n+                {\n+                    _nugetCachePath = PackageDependencyProvider.ResolvePackagesPath(null, null);\n+                }\n+\n+                return _nugetCachePath;\n+            }\n+        }\n+\n+        private string Sentinel => Path.Combine(NuGetCachePath, SENTINEL);\n+\n+        public NuGetCacheSentinel() : this(string.Empty, FileSystemWrapper.Default.File)\n+        {\n+        }\n+\n+        internal NuGetCacheSentinel(string nugetCachePath, IFile file)\n+        {\n+            _file = file;\n+            _nugetCachePath = nugetCachePath;\n+        }\n+\n+        public bool Exists()\n+        {\n+            return _file.Exists(Sentinel);\n+        }\n+\n+        public void CreateIfNotExists()\n+        {\n+            if (!Exists())\n+            {\n+                _file.CreateEmptyFile(Sentinel);","path":"src/Microsoft.DotNet.Configurer/NuGetCacheSentinel.cs","position":53,"original_position":53,"commit_id":"d9b488772b35caac14a0f6cd0e160b55df34c6e2","original_commit_id":"d9b488772b35caac14a0f6cd0e160b55df34c6e2","user":{"login":"livarcocc","id":367554,"avatar_url":"https://avatars.githubusercontent.com/u/367554?v=3","gravatar_id":"","url":"https://api.github.com/users/livarcocc","html_url":"https://github.com/livarcocc","followers_url":"https://api.github.com/users/livarcocc/followers","following_url":"https://api.github.com/users/livarcocc/following{/other_user}","gists_url":"https://api.github.com/users/livarcocc/gists{/gist_id}","starred_url":"https://api.github.com/users/livarcocc/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/livarcocc/subscriptions","organizations_url":"https://api.github.com/users/livarcocc/orgs","repos_url":"https://api.github.com/users/livarcocc/repos","events_url":"https://api.github.com/users/livarcocc/events{/privacy}","received_events_url":"https://api.github.com/users/livarcocc/received_events","type":"User","site_admin":false},"body":"@ericstj You are absolutely right. I am extracting to a temporary folder. After that, NuGet needs to handle that!\r\n\r\nGreat.","created_at":"2016-06-10T19:28:03Z","updated_at":"2016-06-10T19:28:03Z","html_url":"https://github.com/dotnet/cli/pull/3485#discussion_r66668420","pull_request_url":"https://api.github.com/repos/dotnet/cli/pulls/3485","_links":{"self":{"href":"https://api.github.com/repos/dotnet/cli/pulls/comments/66668420"},"html":{"href":"https://github.com/dotnet/cli/pull/3485#discussion_r66668420"},"pull_request":{"href":"https://api.github.com/repos/dotnet/cli/pulls/3485"}}},"pull_request":{"url":"https://api.github.com/repos/dotnet/cli/pulls/3485","id":73319404,"html_url":"https://github.com/dotnet/cli/pull/3485","diff_url":"https://github.com/dotnet/cli/pull/3485.diff","patch_url":"https://github.com/dotnet/cli/pull/3485.patch","issue_url":"https://api.github.com/repos/dotnet/cli/issues/3485","number":3485,"state":"open","locked":false,"title":"Offline feature work","user":{"login":"livarcocc","id":367554,"avatar_url":"https://avatars.githubusercontent.com/u/367554?v=3","gravatar_id":"","url":"https://api.github.com/users/livarcocc","html_url":"https://github.com/livarcocc","followers_url":"https://api.github.com/users/livarcocc/followers","following_url":"https://api.github.com/users/livarcocc/following{/other_user}","gists_url":"https://api.github.com/users/livarcocc/gists{/gist_id}","starred_url":"https://api.github.com/users/livarcocc/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/livarcocc/subscriptions","organizations_url":"https://api.github.com/users/livarcocc/orgs","repos_url":"https://api.github.com/users/livarcocc/repos","events_url":"https://api.github.com/users/livarcocc/events{/privacy}","received_events_url":"https://api.github.com/users/livarcocc/received_events","type":"User","site_admin":false},"body":"Implements a feature that adds a nuget packages archive to the SDK.\r\nWhen the user uses dotnet for the first time, we use that archive to prime the nuget cache without having to hit the network.\r\nAlso added the first time use welcome message (fixes https://github.com/dotnet/cli/issues/3404#event-687899575).\r\n\r\ncc @blackdwarf @ericstj @piotrpMSFT @brthor @eerhardt ","created_at":"2016-06-10T04:10:30Z","updated_at":"2016-06-10T19:28:03Z","closed_at":null,"merged_at":null,"merge_commit_sha":"c099228fe17f7ebaca6010ce545b8d1ce1630f2f","assignee":null,"milestone":null,"commits_url":"https://api.github.com/repos/dotnet/cli/pulls/3485/commits","review_comments_url":"https://api.github.com/repos/dotnet/cli/pulls/3485/comments","review_comment_url":"https://api.github.com/repos/dotnet/cli/pulls/comments{/number}","comments_url":"https://api.github.com/repos/dotnet/cli/issues/3485/comments","statuses_url":"https://api.github.com/repos/dotnet/cli/statuses/d9b488772b35caac14a0f6cd0e160b55df34c6e2","head":{"label":"livarcocc:offline","ref":"offline","sha":"d9b488772b35caac14a0f6cd0e160b55df34c6e2","user":{"login":"livarcocc","id":367554,"avatar_url":"https://avatars.githubusercontent.com/u/367554?v=3","gravatar_id":"","url":"https://api.github.com/users/livarcocc","html_url":"https://github.com/livarcocc","followers_url":"https://api.github.com/users/livarcocc/followers","following_url":"https://api.github.com/users/livarcocc/following{/other_user}","gists_url":"https://api.github.com/users/livarcocc/gists{/gist_id}","starred_url":"https://api.github.com/users/livarcocc/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/livarcocc/subscriptions","organizations_url":"https://api.github.com/users/livarcocc/orgs","repos_url":"https://api.github.com/users/livarcocc/repos","events_url":"https://api.github.com/users/livarcocc/events{/privacy}","received_events_url":"https://api.github.com/users/livarcocc/received_events","type":"User","site_admin":false},"repo":{"id":46442514,"name":"cli-1","full_name":"livarcocc/cli-1","owner":{"login":"livarcocc","id":367554,"avatar_url":"https://avatars.githubusercontent.com/u/367554?v=3","gravatar_id":"","url":"https://api.github.com/users/livarcocc","html_url":"https://github.com/livarcocc","followers_url":"https://api.github.com/users/livarcocc/followers","following_url":"https://api.github.com/users/livarcocc/following{/other_user}","gists_url":"https://api.github.com/users/livarcocc/gists{/gist_id}","starred_url":"https://api.github.com/users/livarcocc/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/livarcocc/subscriptions","organizations_url":"https://api.github.com/users/livarcocc/orgs","repos_url":"https://api.github.com/users/livarcocc/repos","events_url":"https://api.github.com/users/livarcocc/events{/privacy}","received_events_url":"https://api.github.com/users/livarcocc/received_events","type":"User","site_admin":false},"private":false,"html_url":"https://github.com/livarcocc/cli-1","description":"This repo contains the .NET Core command-line (CLI) tools, used for building .NET Core apps and libraries through your development flow (compiling, NuGet package management, running, testing, ...).","fork":true,"url":"https://api.github.com/repos/livarcocc/cli-1","forks_url":"https://api.github.com/repos/livarcocc/cli-1/forks","keys_url":"https://api.github.com/repos/livarcocc/cli-1/keys{/key_id}","collaborators_url":"https://api.github.com/repos/livarcocc/cli-1/collaborators{/collaborator}","teams_url":"https://api.github.com/repos/livarcocc/cli-1/teams","hooks_url":"https://api.github.com/repos/livarcocc/cli-1/hooks","issue_events_url":"https://api.github.com/repos/livarcocc/cli-1/issues/events{/number}","events_url":"https://api.github.com/repos/livarcocc/cli-1/events","assignees_url":"https://api.github.com/repos/livarcocc/cli-1/assignees{/user}","branches_url":"https://api.github.com/repos/livarcocc/cli-1/branches{/branch}","tags_url":"https://api.github.com/repos/livarcocc/cli-1/tags","blobs_url":"https://api.github.com/repos/livarcocc/cli-1/git/blobs{/sha}","git_tags_url":"https://api.github.com/repos/livarcocc/cli-1/git/tags{/sha}","git_refs_url":"https://api.github.com/repos/livarcocc/cli-1/git/refs{/sha}","trees_url":"https://api.github.com/repos/livarcocc/cli-1/git/trees{/sha}","statuses_url":"https://api.github.com/repos/livarcocc/cli-1/statuses/{sha}","languages_url":"https://api.github.com/repos/livarcocc/cli-1/languages","stargazers_url":"https://api.github.com/repos/livarcocc/cli-1/stargazers","contributors_url":"https://api.github.com/repos/livarcocc/cli-1/contributors","subscribers_url":"https://api.github.com/repos/livarcocc/cli-1/subscribers","subscription_url":"https://api.github.com/repos/livarcocc/cli-1/subscription","commits_url":"https://api.github.com/repos/livarcocc/cli-1/commits{/sha}","git_commits_url":"https://api.github.com/repos/livarcocc/cli-1/git/commits{/sha}","comments_url":"https://api.github.com/repos/livarcocc/cli-1/comments{/number}","issue_comment_url":"https://api.github.com/repos/livarcocc/cli-1/issues/comments{/number}","contents_url":"https://api.github.com/repos/livarcocc/cli-1/contents/{+path}","compare_url":"https://api.github.com/repos/livarcocc/cli-1/compare/{base}...{head}","merges_url":"https://api.github.com/repos/livarcocc/cli-1/merges","archive_url":"https://api.github.com/repos/livarcocc/cli-1/{archive_format}{/ref}","downloads_url":"https://api.github.com/repos/livarcocc/cli-1/downloads","issues_url":"https://api.github.com/repos/livarcocc/cli-1/issues{/number}","pulls_url":"https://api.github.com/repos/livarcocc/cli-1/pulls{/number}","milestones_url":"https://api.github.com/repos/livarcocc/cli-1/milestones{/number}","notifications_url":"https://api.github.com/repos/livarcocc/cli-1/notifications{?since,all,participating}","labels_url":"https://api.github.com/repos/livarcocc/cli-1/labels{/name}","releases_url":"https://api.github.com/repos/livarcocc/cli-1/releases{/id}","deployments_url":"https://api.github.com/repos/livarcocc/cli-1/deployments","created_at":"2015-11-18T19:36:02Z","updated_at":"2016-01-11T19:05:14Z","pushed_at":"2016-06-10T04:09:00Z","git_url":"git://github.com/livarcocc/cli-1.git","ssh_url":"git@github.com:livarcocc/cli-1.git","clone_url":"https://github.com/livarcocc/cli-1.git","svn_url":"https://github.com/livarcocc/cli-1","homepage":"http://dotnet.github.io/","size":21944,"stargazers_count":0,"watchers_count":0,"language":"C#","has_issues":false,"has_downloads":true,"has_wiki":true,"has_pages":false,"forks_count":0,"mirror_url":null,"open_issues_count":0,"forks":0,"open_issues":0,"watchers":0,"default_branch":"master"}},"base":{"label":"dotnet:rel/1.0.0-preview2","ref":"rel/1.0.0-preview2","sha":"9e1be7682fb0dc4ca48101083ce78ba775098321","user":{"login":"dotnet","id":9141961,"avatar_url":"https://avatars.githubusercontent.com/u/9141961?v=3","gravatar_id":"","url":"https://api.github.com/users/dotnet","html_url":"https://github.com/dotnet","followers_url":"https://api.github.com/users/dotnet/followers","following_url":"https://api.github.com/users/dotnet/following{/other_user}","gists_url":"https://api.github.com/users/dotnet/gists{/gist_id}","starred_url":"https://api.github.com/users/dotnet/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/dotnet/subscriptions","organizations_url":"https://api.github.com/users/dotnet/orgs","repos_url":"https://api.github.com/users/dotnet/repos","events_url":"https://api.github.com/users/dotnet/events{/privacy}","received_events_url":"https://api.github.com/users/dotnet/received_events","type":"Organization","site_admin":false},"repo":{"id":43568107,"name":"cli","full_name":"dotnet/cli","owner":{"login":"dotnet","id":9141961,"avatar_url":"https://avatars.githubusercontent.com/u/9141961?v=3","gravatar_id":"","url":"https://api.github.com/users/dotnet","html_url":"https://github.com/dotnet","followers_url":"https://api.github.com/users/dotnet/followers","following_url":"https://api.github.com/users/dotnet/following{/other_user}","gists_url":"https://api.github.com/users/dotnet/gists{/gist_id}","starred_url":"https://api.github.com/users/dotnet/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/dotnet/subscriptions","organizations_url":"https://api.github.com/users/dotnet/orgs","repos_url":"https://api.github.com/users/dotnet/repos","events_url":"https://api.github.com/users/dotnet/events{/privacy}","received_events_url":"https://api.github.com/users/dotnet/received_events","type":"Organization","site_admin":false},"private":false,"html_url":"https://github.com/dotnet/cli","description":"This repo contains the .NET Core command-line (CLI) tools, used for building .NET Core apps and libraries through your development flow (compiling, NuGet package management, running, testing, ...).","fork":false,"url":"https://api.github.com/repos/dotnet/cli","forks_url":"https://api.github.com/repos/dotnet/cli/forks","keys_url":"https://api.github.com/repos/dotnet/cli/keys{/key_id}","collaborators_url":"https://api.github.com/repos/dotnet/cli/collaborators{/collaborator}","teams_url":"https://api.github.com/repos/dotnet/cli/teams","hooks_url":"https://api.github.com/repos/dotnet/cli/hooks","issue_events_url":"https://api.github.com/repos/dotnet/cli/issues/events{/number}","events_url":"https://api.github.com/repos/dotnet/cli/events","assignees_url":"https://api.github.com/repos/dotnet/cli/assignees{/user}","branches_url":"https://api.github.com/repos/dotnet/cli/branches{/branch}","tags_url":"https://api.github.com/repos/dotnet/cli/tags","blobs_url":"https://api.github.com/repos/dotnet/cli/git/blobs{/sha}","git_tags_url":"https://api.github.com/repos/dotnet/cli/git/tags{/sha}","git_refs_url":"https://api.github.com/repos/dotnet/cli/git/refs{/sha}","trees_url":"https://api.github.com/repos/dotnet/cli/git/trees{/sha}","statuses_url":"https://api.github.com/repos/dotnet/cli/statuses/{sha}","languages_url":"https://api.github.com/repos/dotnet/cli/languages","stargazers_url":"https://api.github.com/repos/dotnet/cli/stargazers","contributors_url":"https://api.github.com/repos/dotnet/cli/contributors","subscribers_url":"https://api.github.com/repos/dotnet/cli/subscribers","subscription_url":"https://api.github.com/repos/dotnet/cli/subscription","commits_url":"https://api.github.com/repos/dotnet/cli/commits{/sha}","git_commits_url":"https://api.github.com/repos/dotnet/cli/git/commits{/sha}","comments_url":"https://api.github.com/repos/dotnet/cli/comments{/number}","issue_comment_url":"https://api.github.com/repos/dotnet/cli/issues/comments{/number}","contents_url":"https://api.github.com/repos/dotnet/cli/contents/{+path}","compare_url":"https://api.github.com/repos/dotnet/cli/compare/{base}...{head}","merges_url":"https://api.github.com/repos/dotnet/cli/merges","archive_url":"https://api.github.com/repos/dotnet/cli/{archive_format}{/ref}","downloads_url":"https://api.github.com/repos/dotnet/cli/downloads","issues_url":"https://api.github.com/repos/dotnet/cli/issues{/number}","pulls_url":"https://api.github.com/repos/dotnet/cli/pulls{/number}","milestones_url":"https://api.github.com/repos/dotnet/cli/milestones{/number}","notifications_url":"https://api.github.com/repos/dotnet/cli/notifications{?since,all,participating}","labels_url":"https://api.github.com/repos/dotnet/cli/labels{/name}","releases_url":"https://api.github.com/repos/dotnet/cli/releases{/id}","deployments_url":"https://api.github.com/repos/dotnet/cli/deployments","created_at":"2015-10-02T18:03:15Z","updated_at":"2016-06-10T17:48:17Z","pushed_at":"2016-06-10T18:30:55Z","git_url":"git://github.com/dotnet/cli.git","ssh_url":"git@github.com:dotnet/cli.git","clone_url":"https://github.com/dotnet/cli.git","svn_url":"https://github.com/dotnet/cli","homepage":"http://dotnet.github.io/","size":33581,"stargazers_count":1125,"watchers_count":1125,"language":"C#","has_issues":true,"has_downloads":true,"has_wiki":true,"has_pages":false,"forks_count":250,"mirror_url":null,"open_issues_count":756,"forks":250,"open_issues":756,"watchers":1125,"default_branch":"rel/1.0.0"}},"_links":{"self":{"href":"https://api.github.com/repos/dotnet/cli/pulls/3485"},"html":{"href":"https://github.com/dotnet/cli/pull/3485"},"issue":{"href":"https://api.github.com/repos/dotnet/cli/issues/3485"},"comments":{"href":"https://api.github.com/repos/dotnet/cli/issues/3485/comments"},"review_comments":{"href":"https://api.github.com/repos/dotnet/cli/pulls/3485/comments"},"review_comment":{"href":"https://api.github.com/repos/dotnet/cli/pulls/comments{/number}"},"commits":{"href":"https://api.github.com/repos/dotnet/cli/pulls/3485/commits"},"statuses":{"href":"https://api.github.com/repos/dotnet/cli/statuses/d9b488772b35caac14a0f6cd0e160b55df34c6e2"}}}}
{"actor":{"display_login":"livarcocc"}}