Skip to content
This repository was archived by the owner on Feb 12, 2023. It is now read-only.

Commit a361981

Browse files
Merge branch 'release/1.1.0'
2 parents e959537 + de2f7f9 commit a361981

File tree

9 files changed

+107
-8
lines changed

9 files changed

+107
-8
lines changed

README.md

Lines changed: 48 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -7,7 +7,7 @@ GitHubLink let's users step through your code hosted on GitHub! **This makes sym
77

88
![Stepping through external source code](doc/images/GitHubLink_example.gif)
99

10-
The idea is based on the [SourceLink project](https://github.com/ctaggart/SourceLink "SourceLink project"). However it requires FAKE and no everyone likes to write code in F#. GitHubLink is available as console application and can be references as assembly as well to be used in other .NET assemblies.
10+
The idea is based on the [SourceLink project](https://github.com/ctaggart/SourceLink "SourceLink project"). However it requires FAKE and not everyone likes to write code in F#. GitHubLink is available as console application and can be references as assembly as well to be used in other .NET assemblies.
1111

1212
The advantage of GitHubLink is that it is fully customized for GitHub. It also works with GitHub urls so it **does not require a local git repository to work**. This makes it perfectly usable in continuous integration servers such as [Continua CI](http://www.finalbuilder.com/Continua-CI "Continua CI").
1313

@@ -17,9 +17,9 @@ When using GitHubLink, the user no longer has to specify symbol servers. He/she
1717

1818
![Enabling source server support](doc/images/visualstudio_enablesourceserversupport.png)
1919

20-
# Using GitHubLink #
20+
# Using GitHubLink as command line tool #
2121

22-
Using GitHubLink is very simple:
22+
Using GitHubLink via the command line is very simple:
2323

2424
1. Build the software (in release mode with pdb files enabled)
2525
2. Run the console application with the right command line parameters
@@ -57,6 +57,51 @@ When you need to log the information to a file, use the following command line:
5757
GitHubLink.exe c:\source\catel -u https://github.com/catel/catel -b develop -l GitHubLinkLog.log
5858

5959

60+
# Using GitHubLink in code #
61+
62+
GitHubLink is built with 2 usages in mind: command line and code reference. Though most people will use the command line version, it is possible to reference the executable and use the logic in code.
63+
64+
The command line implementation uses the same available API.
65+
66+
## Creating a context ##
67+
68+
To link files to a GitHub project, a context must be created. The command line version does this by using the *ArgumentParser* class. It is also possible to create a context from scratch as shown in the example below:
69+
70+
var context = new GitHubLink.Context();
71+
context.SolutionDirectory = @"c:\source\catel";
72+
context.TargetUrl = "https://github.com/catel/catel";
73+
context.TargetBranch = "develop";
74+
75+
It is possible to create a context based on command line arguments:
76+
77+
var context = ArgumentParser.Parse(@"c:\source\catel -u https://github.com/catel/catel -b develop");
78+
79+
## Linking a context ##
80+
81+
Once a context is created, the *Linker* class can be used to actually link the files:
82+
83+
Linker.Link(context);
84+
85+
# How to get GitHubLink #
86+
87+
There are three general ways to get GitHubLink:.
88+
89+
## Get it from GitHub ##
90+
91+
The releases will be available as separate executable download on the [releases tab](https://github.com/GeertvanHorrik/GitHubLink/releases) of the project.
92+
93+
## Get it via Chocolatey ##
94+
95+
If you want to install the tool on your (build) computer, the package is available via [Chocolatey](https://chocolatey.org/). To install, use the following command:
96+
97+
cinst GitHubLink
98+
99+
## Get it via NuGet ##
100+
101+
If you want to reference the assembly to use it in code, the recommended way to get it is via [NuGet](http://www.nuget.org/).
102+
103+
**Note that getting GitHubLink via NuGet will add it as a reference to the project**
104+
60105
# How does it work #
61106

62107
The SrcSrv tool (Srcsrv.dll) enables a client to retrieve the exact version of the source files that were used to build an application. Because the source code for a module can change between versions and over the course of years, it is important to look at the source code as it existed when the version of the module in question was built.
Lines changed: 24 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,24 @@
1+
<?xml version="1.0" encoding="utf-8"?>
2+
<package>
3+
<metadata>
4+
<id>githublink</id>
5+
<version>[VERSION]</version>
6+
<title>GitHubLink</title>
7+
<authors>GeertvanHorrik</authors>
8+
9+
<description>
10+
GitHubLink let's users step through your code hosted on GitHub! This makes symbol servers obsolete which saves you both time
11+
with uploading source files with symbols and the user no longer has to specify custom symbol servers (such as symbolsource.org).
12+
</description>
13+
14+
<summary>
15+
</summary>
16+
17+
<tags>source symbol symbols server sourcelink github stepping debugging</tags>
18+
19+
<language>en-US</language>
20+
<projectUrl>https://github.com/GeertvanHorrik/GitHubLink/</projectUrl>
21+
<licenseUrl>https://github.com/GeertvanHorrik/GitHubLink/blob/develop/LICENSE</licenseUrl>
22+
<iconUrl>https://raw.githubusercontent.com/GeertvanHorrik/GitHubLink/develop/design/logo/logo_64.png</iconUrl>
23+
</metadata>
24+
</package>
Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,2 @@
1+
Generate-BinFile "ghl" "$packageFolder\Tools\GitHubLink.exe"
2+
Write-ChocolateySuccess "GitHubLink"
Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,3 @@
1+
Remove-BinFile "ghl" "$packageFolder\Tools\GitHubLink.exe"
2+
Remove-BinFile "GitHubLink" "$packageFolder\Tools\GitHubLink.exe"
3+
Write-ChocolateySuccess "GitHubLink"
Binary file not shown.

deployment/NuGet/template/GitHubLink.nuspec

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,7 @@
11
<?xml version="1.0" encoding="utf-8"?>
22
<package>
33
<metadata>
4-
<id>GitHubLink</id>
4+
<id>githublink</id>
55
<version>[VERSION]</version>
66
<title>GitHubLink</title>
77
<authors>GeertvanHorrik</authors>

doc/history.txt

Lines changed: 25 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -13,7 +13,7 @@ Project website: https://github.com/GeertvanHorrik/GitHubLink
1313
**********************************************************
1414

1515
==================
16-
Version 1.0.0
16+
Version 1.1.0
1717
==================
1818

1919
Release date:
@@ -22,7 +22,30 @@ Release date:
2222

2323
Added/fixed:
2424
============
25-
xxx
25+
xx
26+
27+
Roadmap:
28+
========
29+
See https://github.com/GeertvanHorrik/GitHubLink
30+
31+
Known issues:
32+
=============
33+
See https://github.com/GeertvanHorrik/GitHubLink
34+
35+
**********************************************************
36+
37+
38+
==================
39+
Version 1.0.0
40+
==================
41+
42+
Release date:
43+
=============
44+
2014/04/17
45+
46+
Added/fixed:
47+
============
48+
First initial release
2649

2750
Roadmap:
2851
========

src/GitHubLink/Context.cs

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -27,7 +27,7 @@ public Context()
2727

2828
public string SolutionDirectory { get; set; }
2929
public string ConfigurationName { get; set; }
30-
public string TempDirectory { get; set; }
30+
public string TempDirectory { get; private set; }
3131

3232
public string TargetUrl { get; set; }
3333
public string TargetBranch { get; set; }

src/GitHubLink/Linker.cs

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -49,7 +49,9 @@ public static int Link(Context context)
4949
var gitPreparer = new GitPreparer(context);
5050
gitPreparer.Prepare();
5151

52-
var projectFiles = Directory.GetFiles(context.SolutionDirectory, "*.csproj", SearchOption.AllDirectories);
52+
var projectFiles = new List<string>();
53+
projectFiles.AddRange(Directory.GetFiles(context.SolutionDirectory, "*.csproj", SearchOption.AllDirectories));
54+
projectFiles.AddRange(Directory.GetFiles(context.SolutionDirectory, "*.vbproj", SearchOption.AllDirectories));
5355

5456
int projectCount = projectFiles.Count();
5557
var failedProjects = new List<string>();

0 commit comments

Comments
 (0)