Compare commits
3 Commits
| Author | SHA1 | Date | |
|---|---|---|---|
| 8a0232129f | |||
| 8c043dc18e | |||
| f56028b6a2 |
@@ -6,11 +6,11 @@
|
|||||||
xmlns:local="clr-namespace:Txt2Bib"
|
xmlns:local="clr-namespace:Txt2Bib"
|
||||||
mc:Ignorable="d"
|
mc:Ignorable="d"
|
||||||
Title="MainWindow" Height="744" Width="800">
|
Title="MainWindow" Height="744" Width="800">
|
||||||
<Grid Background="#FF38383E" Margin="0,0,0,-6">
|
<Grid Background="#FF38383E" Margin="0,0,0,-16">
|
||||||
<TextBox x:Name="DropArea" Text="Trascinare qui i file txt da convertire" ToolTip="Trascinare qui i file txt da convertire" HorizontalAlignment="Left" Margin="48,82,0,0" TextWrapping="Wrap" VerticalAlignment="Top" Width="526" Height="437" PreviewDragEnter="DropArea_PreviewDragEnter" PreviewDragOver="DropArea_PreviewDragOver" Drop="DropArea_Drop"/>
|
<TextBox x:Name="DropArea" Text="Trascinare qui i file txt da convertire" ToolTip="Trascinare qui i file txt da convertire" HorizontalAlignment="Left" Margin="48,105,0,0" TextWrapping="Wrap" VerticalAlignment="Top" Width="710" Height="245" PreviewDragEnter="DropArea_PreviewDragEnter" PreviewDragOver="DropArea_PreviewDragOver" Drop="DropArea_Drop"/>
|
||||||
<TextBox x:Name="Debug" VerticalScrollBarVisibility="Auto" IsEnabled="True" HorizontalAlignment="Left" Margin="48,571,0,0" TextWrapping="Wrap" VerticalAlignment="Top" Width="710" Height="106" RenderTransformOrigin="0.449,1.525"/>
|
<TextBox x:Name="Debug" VerticalScrollBarVisibility="Auto" IsEnabled="True" HorizontalAlignment="Left" Margin="48,458,0,0" TextWrapping="Wrap" VerticalAlignment="Top" Width="710" Height="224" RenderTransformOrigin="0.449,1.525"/>
|
||||||
<Label Content="Txt2Bib" HorizontalAlignment="Center" Margin="0,10,0,0" VerticalAlignment="Top" Foreground="White" FontFamily="Eras ITC" FontSize="28"/>
|
<Label Content="Txt2Bib" HorizontalAlignment="Center" Margin="0,10,0,0" VerticalAlignment="Top" Foreground="White" FontFamily="Eras ITC" FontSize="28"/>
|
||||||
<Button x:Name="GoBtn" Cursor="Hand" Content="Genera" HorizontalAlignment="Left" Margin="631,82,0,0" VerticalAlignment="Top" RenderTransformOrigin="0.5,0.5" Height="68" Width="127" Click="GoBtn_Click" BorderBrush="{x:Null}" Foreground="White" Background="#FF474671" FontFamily="Cascadia Code" FontSize="16">
|
<Button x:Name="GoBtn" Cursor="Hand" Content="Esegui" HorizontalAlignment="Left" Margin="340,367,0,0" VerticalAlignment="Top" RenderTransformOrigin="0.5,0.5" Height="50" Width="126" Click="GoBtn_Click" BorderBrush="{x:Null}" Foreground="White" Background="#FF3F9865" FontFamily="Cascadia Code" FontSize="16">
|
||||||
<Button.RenderTransform>
|
<Button.RenderTransform>
|
||||||
<TransformGroup>
|
<TransformGroup>
|
||||||
<ScaleTransform/>
|
<ScaleTransform/>
|
||||||
@@ -20,15 +20,26 @@
|
|||||||
</TransformGroup>
|
</TransformGroup>
|
||||||
</Button.RenderTransform>
|
</Button.RenderTransform>
|
||||||
</Button>
|
</Button>
|
||||||
<Label Content="Debug" HorizontalAlignment="Left" Margin="44,544,0,0" VerticalAlignment="Top" Foreground="White"/>
|
<Label Content="Preview" HorizontalAlignment="Left" Margin="46,421,0,0" VerticalAlignment="Top" Foreground="White"/>
|
||||||
<Button x:Name="CopyDebug" Content="Button" HorizontalAlignment="Left" Margin="111,547,0,0" VerticalAlignment="Top" Foreground="{x:Null}" BorderBrush="{x:Null}" Width="23" Background="White" Click="CopyDebug_Click">
|
<Button x:Name="CopyDebug" ToolTip="Copia contenuto preview negli appunti" Cursor="Hand" Content="Button" HorizontalAlignment="Left" Margin="110,424,0,0" VerticalAlignment="Top" Foreground="{x:Null}" BorderBrush="{x:Null}" Width="26" Background="White" Click="CopyDebug_Click" RenderTransformOrigin="0.554,-4.344" Height="23">
|
||||||
<Button.OpacityMask>
|
<Button.OpacityMask>
|
||||||
<ImageBrush ImageSource="/copy-icon.png"/>
|
<ImageBrush Stretch="Uniform" ImageSource="/copy-icon.png"/>
|
||||||
</Button.OpacityMask>
|
</Button.OpacityMask>
|
||||||
</Button>
|
</Button>
|
||||||
<Button x:Name="OpenDestFolderBtn" ToolTip="Apri cartella destinazione" Content="Button" HorizontalAlignment="Left" Margin="631,168,0,0" VerticalAlignment="Top" BorderBrush="{x:Null}" Foreground="{x:Null}" Height="26" Width="27" Cursor="Hand" Click="OpenDestFolderBtn_Click">
|
<Menu x:Name="FileMenu" Margin="22,56,607,476" Background="#FF4B4E5D" Visibility="Collapsed">
|
||||||
|
<Menu.ItemsPanel>
|
||||||
|
<ItemsPanelTemplate>
|
||||||
|
<VirtualizingStackPanel Orientation="Vertical"/>
|
||||||
|
</ItemsPanelTemplate>
|
||||||
|
</Menu.ItemsPanel>
|
||||||
|
<Label x:Name="MenuExec" Content="Esegui..." Foreground="White" FontSize="14" MouseDown="MenuExec_MouseDown" Cursor="Hand"/>
|
||||||
|
<Label x:Name="OpenOutputDir" Content="Apri cartella output" Foreground="White" FontSize="14" MouseDown="OpenOutputDir_MouseDown" Cursor="Hand"/>
|
||||||
|
<Label x:Name="Help" Content="Help" Foreground="White" FontSize="14" MouseDown="Help_MouseDown" Cursor="Hand"/>
|
||||||
|
<Label x:Name="Exit" Content="Esci..." Foreground="White" FontSize="14" MouseDown="Exit_MouseDown" Cursor="Hand"/>
|
||||||
|
</Menu>
|
||||||
|
<Button x:Name="ToggleMenu" Content="" HorizontalAlignment="Left" Margin="12,14,0,0" VerticalAlignment="Top" RenderTransformOrigin="0,0.202" Height="42" Width="47" BorderBrush="{x:Null}" Foreground="{x:Null}" Cursor="Hand" Click="ToggleMenu_Click">
|
||||||
<Button.OpacityMask>
|
<Button.OpacityMask>
|
||||||
<ImageBrush ImageSource="/openfolder_4896.png" Stretch="Uniform"/>
|
<ImageBrush ImageSource="/menu-1768000-1502336.png" Stretch="Uniform"/>
|
||||||
</Button.OpacityMask>
|
</Button.OpacityMask>
|
||||||
</Button>
|
</Button>
|
||||||
|
|
||||||
|
|||||||
@@ -16,9 +16,22 @@ namespace Txt2Bib
|
|||||||
public MainWindow()
|
public MainWindow()
|
||||||
{
|
{
|
||||||
InitializeComponent();
|
InitializeComponent();
|
||||||
|
OutputDir = $@"{Directory.GetCurrentDirectory()}\bibtex";
|
||||||
|
Directory.CreateDirectory(OutputDir);
|
||||||
DropArea.AllowDrop = true;
|
DropArea.AllowDrop = true;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
private string OutputDir { get; }
|
||||||
|
|
||||||
|
private void Execute()
|
||||||
|
{
|
||||||
|
var txt2bib = new Text2Bib();
|
||||||
|
var result = txt2bib.Generate(DropArea.Text);
|
||||||
|
Debug.Text = result;
|
||||||
|
using var outputFile = new StreamWriter($@"{OutputDir}\output_bibtex.bib");
|
||||||
|
outputFile.Write(result);
|
||||||
|
}
|
||||||
|
|
||||||
private void DropArea_Drop(object sender, DragEventArgs e)
|
private void DropArea_Drop(object sender, DragEventArgs e)
|
||||||
{
|
{
|
||||||
// Get data object
|
// Get data object
|
||||||
@@ -38,7 +51,7 @@ namespace Txt2Bib
|
|||||||
|
|
||||||
// Process file names
|
// Process file names
|
||||||
var fileNames = dataObject.GetFileDropList();
|
var fileNames = dataObject.GetFileDropList();
|
||||||
StringBuilder bd = new StringBuilder();
|
var bd = new StringBuilder();
|
||||||
foreach (var fileName in fileNames)
|
foreach (var fileName in fileNames)
|
||||||
{
|
{
|
||||||
bd.Append(fileName + "\n");
|
bd.Append(fileName + "\n");
|
||||||
@@ -67,11 +80,7 @@ namespace Txt2Bib
|
|||||||
|
|
||||||
private void GoBtn_Click(object sender, RoutedEventArgs e)
|
private void GoBtn_Click(object sender, RoutedEventArgs e)
|
||||||
{
|
{
|
||||||
var txt2bib = new Text2Bib();
|
Execute();
|
||||||
var result = txt2bib.Generate(DropArea.Text);
|
|
||||||
Debug.Text = result;
|
|
||||||
using var outputFile = new StreamWriter("output_bibtex.bib");
|
|
||||||
outputFile.Write(result);
|
|
||||||
}
|
}
|
||||||
|
|
||||||
private void CopyDebug_Click(object sender, RoutedEventArgs e)
|
private void CopyDebug_Click(object sender, RoutedEventArgs e)
|
||||||
@@ -82,7 +91,41 @@ namespace Txt2Bib
|
|||||||
|
|
||||||
private void OpenDestFolderBtn_Click(object sender, RoutedEventArgs e)
|
private void OpenDestFolderBtn_Click(object sender, RoutedEventArgs e)
|
||||||
{
|
{
|
||||||
System.Diagnostics.Process.Start("explorer.exe", Directory.GetCurrentDirectory());
|
System.Diagnostics.Process.Start("explorer.exe", OutputDir);
|
||||||
|
}
|
||||||
|
|
||||||
|
private void ToggleMenu_Click(object sender, RoutedEventArgs e)
|
||||||
|
{
|
||||||
|
if (FileMenu.Visibility == Visibility.Collapsed)
|
||||||
|
{
|
||||||
|
FileMenu.Visibility = Visibility.Visible;
|
||||||
|
}
|
||||||
|
else
|
||||||
|
{
|
||||||
|
FileMenu.Visibility = Visibility.Collapsed;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
private void OpenOutputDir_MouseDown(object sender, System.Windows.Input.MouseButtonEventArgs e)
|
||||||
|
{
|
||||||
|
System.Diagnostics.Process.Start("explorer.exe", OutputDir);
|
||||||
|
}
|
||||||
|
|
||||||
|
private void MenuExec_MouseDown(object sender, System.Windows.Input.MouseButtonEventArgs e)
|
||||||
|
{
|
||||||
|
Execute();
|
||||||
|
}
|
||||||
|
|
||||||
|
private void Exit_MouseDown(object sender, System.Windows.Input.MouseButtonEventArgs e)
|
||||||
|
{
|
||||||
|
Environment.Exit(0);
|
||||||
|
}
|
||||||
|
|
||||||
|
private void Help_MouseDown(object sender, System.Windows.Input.MouseButtonEventArgs e)
|
||||||
|
{
|
||||||
|
MessageBox.Show("Trascinare i file txt da elaborare nella casella in alto e premere 'Esegui'.\n" +
|
||||||
|
"Il file BibTeX viene generato in una cartella dedicata, che si può aprire selezionando " +
|
||||||
|
"'Apri cartella output' dal menu.", "Help", MessageBoxButton.OK, MessageBoxImage.Information);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|||||||
37
Records.cs
37
Records.cs
@@ -1,7 +1,10 @@
|
|||||||
using System;
|
using System;
|
||||||
|
using System.CodeDom;
|
||||||
using System.Configuration;
|
using System.Configuration;
|
||||||
using System.Linq;
|
using System.Linq;
|
||||||
using System.Text.RegularExpressions;
|
using System.Text.RegularExpressions;
|
||||||
|
using System.Windows.Media.Converters;
|
||||||
|
using System.Windows.Navigation;
|
||||||
|
|
||||||
namespace Txt2Bib.Records
|
namespace Txt2Bib.Records
|
||||||
{
|
{
|
||||||
@@ -14,8 +17,8 @@ namespace Txt2Bib.Records
|
|||||||
public string Title { get; set; } = "";
|
public string Title { get; set; } = "";
|
||||||
public string Journal { get; set; } = "";
|
public string Journal { get; set; } = "";
|
||||||
public ushort Year { get; set; } = 1950;
|
public ushort Year { get; set; } = 1950;
|
||||||
public ushort Volume { get; set; } = 1;
|
public string Volume { get; set; } = "";
|
||||||
public byte? Issue { get; set; } = null;
|
public string? Issue { get; set; } = null;
|
||||||
public ushort FirstPage { get; set; } = 1;
|
public ushort FirstPage { get; set; } = 1;
|
||||||
public ushort LastPage { get; set; } = 1;
|
public ushort LastPage { get; set; } = 1;
|
||||||
public string Doi { get; set; } = "";
|
public string Doi { get; set; } = "";
|
||||||
@@ -29,18 +32,26 @@ namespace Txt2Bib.Records
|
|||||||
a = a.Trim();
|
a = a.Trim();
|
||||||
var s = a.Split(' ');
|
var s = a.Split(' ');
|
||||||
return $"{s[1]} {s[0]}";
|
return $"{s[1]} {s[0]}";
|
||||||
};
|
};
|
||||||
|
var checkVol = (string v) =>
|
||||||
|
v.Split(',').Length == 2 ? v.Split(',')[0] : v;
|
||||||
|
|
||||||
Author = temp.Select(a => rearrange(a)).ToArray();
|
Author = temp.Select(a => rearrange(a)).ToArray();
|
||||||
Year = ushort.Parse(entryLines[2]);
|
Year = ushort.Parse(entryLines[2]);
|
||||||
Title = entryLines[3];
|
Title = entryLines[3];
|
||||||
Journal = entryLines[4];
|
Journal = entryLines[4];
|
||||||
Volume = entryLines[5].Split(',').Length == 2 ?
|
Volume = entryLines[5] != string.Empty ? checkVol(entryLines[5]) : Volume;
|
||||||
byte.Parse(entryLines[5].Split(',')[0]) :
|
|
||||||
byte.Parse(entryLines[5]);
|
|
||||||
Issue = entryLines[5].Split(',').Length == 2 ?
|
Issue = entryLines[5].Split(',').Length == 2 ?
|
||||||
byte.Parse(entryLines[5].Split(',')[1]) : null;
|
entryLines[5].Split(',')[1] : Issue;
|
||||||
FirstPage = ushort.Parse(entryLines[6].Split('-')[0]);
|
try
|
||||||
LastPage = ushort.Parse(entryLines[6].Split('-')[1]);
|
{
|
||||||
|
FirstPage = ushort.Parse(entryLines[6].Split('-')[0]);
|
||||||
|
LastPage = ushort.Parse(entryLines[6].Split('-')[1]);
|
||||||
|
}
|
||||||
|
catch (Exception)
|
||||||
|
{
|
||||||
|
throw;
|
||||||
|
}
|
||||||
Doi = entryLines.Length > 7 ? entryLines[7] : "";
|
Doi = entryLines.Length > 7 ? entryLines[7] : "";
|
||||||
|
|
||||||
return ToString();
|
return ToString();
|
||||||
@@ -48,12 +59,14 @@ namespace Txt2Bib.Records
|
|||||||
|
|
||||||
public override string ToString()
|
public override string ToString()
|
||||||
{
|
{
|
||||||
return $"@{Type}" + "{" +$"{Author[0][..5]}_{Year},\n" +
|
var volNum = Volume.Equals(byte.MinValue) ? "" : $"\"{Volume}\"";
|
||||||
|
|
||||||
|
return $"@{Type}{{{Author[0][..5]}_{Year},\n" +
|
||||||
$"\tauthor = \"{string.Join(" and ", Author)}\",\n" +
|
$"\tauthor = \"{string.Join(" and ", Author)}\",\n" +
|
||||||
$"\ttitle = {{{Title}}},\n" +
|
$"\ttitle = {{{Title}}},\n" +
|
||||||
$"\tjournal = \"{Journal}\",\n" +
|
$"\tjournal = \"{Journal}\",\n" +
|
||||||
$"\tyear = \"{Year}\",\n" +
|
$"\tyear = \"{Year}\",\n" +
|
||||||
$"\tvolume = \"{Volume}\",\n" +
|
$"\tvolume = \"{volNum}\",\n" +
|
||||||
$"\tnumber = \"{Issue}\",\n" +
|
$"\tnumber = \"{Issue}\",\n" +
|
||||||
$"\tpages = \"{FirstPage}--{LastPage}\",\n" +
|
$"\tpages = \"{FirstPage}--{LastPage}\",\n" +
|
||||||
$"\tdoi = \"{Doi}\",\n" +
|
$"\tdoi = \"{Doi}\",\n" +
|
||||||
@@ -74,7 +87,7 @@ namespace Txt2Bib.Records
|
|||||||
|
|
||||||
public override string ToString()
|
public override string ToString()
|
||||||
{
|
{
|
||||||
return $"@{Type}" + "{" +$"{Author[0][..5]}_{Year},\n" +
|
return $"@{Type}{{{Author[0][..5]}_{Year},\n" +
|
||||||
$"\tauthor = \"{string.Join(" and", Author)}\",\n" +
|
$"\tauthor = \"{string.Join(" and", Author)}\",\n" +
|
||||||
$"\ttitle = {{{Title}}},\n" +
|
$"\ttitle = {{{Title}}},\n" +
|
||||||
$"\tpublisher = \"{Publisher}\",\n" +
|
$"\tpublisher = \"{Publisher}\",\n" +
|
||||||
|
|||||||
53
Text2Bib.cs
53
Text2Bib.cs
@@ -16,6 +16,7 @@ namespace Txt2Bib
|
|||||||
public class Text2Bib
|
public class Text2Bib
|
||||||
{
|
{
|
||||||
private string[] _citTypes = { "J", "B", "C", "P", "?" };
|
private string[] _citTypes = { "J", "B", "C", "P", "?" };
|
||||||
|
|
||||||
/// <summary>
|
/// <summary>
|
||||||
/// Generate single .bib file from input text files
|
/// Generate single .bib file from input text files
|
||||||
/// </summary>
|
/// </summary>
|
||||||
@@ -24,33 +25,43 @@ namespace Txt2Bib
|
|||||||
public string Generate(string filenames)
|
public string Generate(string filenames)
|
||||||
{
|
{
|
||||||
var paths = filenames.Trim().Split('\n');
|
var paths = filenames.Trim().Split('\n');
|
||||||
string result = "";
|
var output = "";
|
||||||
string output = "";
|
|
||||||
|
|
||||||
foreach (var path in paths)
|
foreach (var path in paths)
|
||||||
{
|
{
|
||||||
var reader = File.OpenText(path);
|
output += CreateBibTeX(path);
|
||||||
byte[] contentBytes = File.ReadAllBytes(path);
|
|
||||||
|
|
||||||
result += Encoding.Latin1.GetString(contentBytes);
|
|
||||||
}
|
}
|
||||||
|
|
||||||
|
return output;
|
||||||
|
}
|
||||||
|
/// <summary>
|
||||||
|
/// Create a BibTeX string from an input file path
|
||||||
|
/// </summary>
|
||||||
|
/// <param name="path"></param>
|
||||||
|
/// <returns></returns>
|
||||||
|
public string CreateBibTeX(string path)
|
||||||
|
{
|
||||||
|
var reader = File.OpenText(path);
|
||||||
|
byte[] contentBytes = File.ReadAllBytes(path);
|
||||||
|
var content = Encoding.Latin1.GetString(contentBytes);
|
||||||
|
|
||||||
IEnumerable<string> entries = new List<string>();
|
IEnumerable<string> entries = new List<string>();
|
||||||
try
|
try
|
||||||
{
|
{
|
||||||
entries = result.Split('%').ToList().Select(entry => Process(entry));
|
entries = content.Split('%').ToList().Select(entry => Process(entry));
|
||||||
}
|
}
|
||||||
catch (Exception)
|
catch (Exception)
|
||||||
{
|
{
|
||||||
throw;
|
throw;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
var bibtex = "";
|
||||||
foreach (var entry in entries)
|
foreach (var entry in entries)
|
||||||
{
|
{
|
||||||
output += entry;
|
bibtex += entry;
|
||||||
}
|
}
|
||||||
|
|
||||||
return output;
|
return bibtex;
|
||||||
}
|
}
|
||||||
/// <summary>
|
/// <summary>
|
||||||
/// Creates a bib entry from source text
|
/// Creates a bib entry from source text
|
||||||
@@ -66,14 +77,23 @@ namespace Txt2Bib
|
|||||||
|
|
||||||
if (!IsValidEntry(type)) throw new Exception($"Invalid entry type '{type}'");
|
if (!IsValidEntry(type)) throw new Exception($"Invalid entry type '{type}'");
|
||||||
|
|
||||||
string citation = type switch
|
string citation = "";
|
||||||
|
|
||||||
|
try
|
||||||
{
|
{
|
||||||
"J" => (new ArticleBib()).Convert(lines),
|
citation = type switch
|
||||||
//"B" => new BookBib(),
|
{
|
||||||
//"C" => new ChapterBib(),
|
"J" => (new ArticleBib()).Convert(lines),
|
||||||
//"P" => new ConferenceBib(),
|
//"B" => new BookBib(),
|
||||||
_ => (new ArticleBib()).Convert(lines)
|
//"C" => new ChapterBib(),
|
||||||
};
|
//"P" => new ConferenceBib(),
|
||||||
|
_ => (new ArticleBib()).Convert(lines)
|
||||||
|
};
|
||||||
|
}
|
||||||
|
catch (Exception)
|
||||||
|
{
|
||||||
|
throw new Exception("Faulty string in " + lines);
|
||||||
|
}
|
||||||
|
|
||||||
return citation;
|
return citation;
|
||||||
}
|
}
|
||||||
@@ -95,7 +115,6 @@ namespace Txt2Bib
|
|||||||
{
|
{
|
||||||
var cp = "UTF-8";
|
var cp = "UTF-8";
|
||||||
return Encoding.GetEncoding(cp);
|
return Encoding.GetEncoding(cp);
|
||||||
|
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -9,11 +9,13 @@
|
|||||||
|
|
||||||
<ItemGroup>
|
<ItemGroup>
|
||||||
<None Remove="copy-icon.png" />
|
<None Remove="copy-icon.png" />
|
||||||
|
<None Remove="menu-1768000-1502336.png" />
|
||||||
<None Remove="openfolder_4896.png" />
|
<None Remove="openfolder_4896.png" />
|
||||||
</ItemGroup>
|
</ItemGroup>
|
||||||
|
|
||||||
<ItemGroup>
|
<ItemGroup>
|
||||||
<Resource Include="copy-icon.png" />
|
<Resource Include="copy-icon.png" />
|
||||||
|
<Resource Include="menu-1768000-1502336.png" />
|
||||||
<Resource Include="openfolder_4896.png" />
|
<Resource Include="openfolder_4896.png" />
|
||||||
</ItemGroup>
|
</ItemGroup>
|
||||||
|
|
||||||
|
|||||||
9
docfx_project/.gitignore
vendored
Normal file
9
docfx_project/.gitignore
vendored
Normal file
@@ -0,0 +1,9 @@
|
|||||||
|
###############
|
||||||
|
# folder #
|
||||||
|
###############
|
||||||
|
/**/DROP/
|
||||||
|
/**/TEMP/
|
||||||
|
/**/packages/
|
||||||
|
/**/bin/
|
||||||
|
/**/obj/
|
||||||
|
_site
|
||||||
5
docfx_project/api/.gitignore
vendored
Normal file
5
docfx_project/api/.gitignore
vendored
Normal file
@@ -0,0 +1,5 @@
|
|||||||
|
###############
|
||||||
|
# temp file #
|
||||||
|
###############
|
||||||
|
*.yml
|
||||||
|
.manifest
|
||||||
2
docfx_project/api/index.md
Normal file
2
docfx_project/api/index.md
Normal file
@@ -0,0 +1,2 @@
|
|||||||
|
# PLACEHOLDER
|
||||||
|
TODO: Add .NET projects to the *src* folder and run `docfx` to generate **REAL** *API Documentation*!
|
||||||
1
docfx_project/articles/intro.md
Normal file
1
docfx_project/articles/intro.md
Normal file
@@ -0,0 +1 @@
|
|||||||
|
# Add your introductions here!
|
||||||
2
docfx_project/articles/toc.yml
Normal file
2
docfx_project/articles/toc.yml
Normal file
@@ -0,0 +1,2 @@
|
|||||||
|
- name: Introduction
|
||||||
|
href: intro.md
|
||||||
65
docfx_project/docfx.json
Normal file
65
docfx_project/docfx.json
Normal file
@@ -0,0 +1,65 @@
|
|||||||
|
{
|
||||||
|
"metadata": [
|
||||||
|
{
|
||||||
|
"src": [
|
||||||
|
{
|
||||||
|
"files": [
|
||||||
|
"*.csproj"
|
||||||
|
],
|
||||||
|
"src" : "../"
|
||||||
|
}
|
||||||
|
],
|
||||||
|
"dest": "api",
|
||||||
|
"disableGitFeatures": true,
|
||||||
|
"disableDefaultFilter": false
|
||||||
|
}
|
||||||
|
],
|
||||||
|
"build": {
|
||||||
|
"content": [
|
||||||
|
{
|
||||||
|
"files": [
|
||||||
|
"api/**.yml",
|
||||||
|
"api/index.md"
|
||||||
|
]
|
||||||
|
},
|
||||||
|
{
|
||||||
|
"files": [
|
||||||
|
"articles/**.md",
|
||||||
|
"articles/**/toc.yml",
|
||||||
|
"toc.yml",
|
||||||
|
"*.md"
|
||||||
|
]
|
||||||
|
}
|
||||||
|
],
|
||||||
|
"resource": [
|
||||||
|
{
|
||||||
|
"files": [
|
||||||
|
"images/**"
|
||||||
|
]
|
||||||
|
}
|
||||||
|
],
|
||||||
|
"overwrite": [
|
||||||
|
{
|
||||||
|
"files": [
|
||||||
|
"apidoc/**.md"
|
||||||
|
],
|
||||||
|
"exclude": [
|
||||||
|
"obj/**",
|
||||||
|
"_site/**"
|
||||||
|
]
|
||||||
|
}
|
||||||
|
],
|
||||||
|
"dest": "_site",
|
||||||
|
"globalMetadataFiles": [],
|
||||||
|
"fileMetadataFiles": [],
|
||||||
|
"template": [
|
||||||
|
"modern"
|
||||||
|
],
|
||||||
|
"postProcessors": [],
|
||||||
|
"markdownEngineName": "markdig",
|
||||||
|
"noLangKeyword": false,
|
||||||
|
"keepFileLink": false,
|
||||||
|
"cleanupCacheHistory": false,
|
||||||
|
"disableGitFeatures": false
|
||||||
|
}
|
||||||
|
}
|
||||||
4
docfx_project/index.md
Normal file
4
docfx_project/index.md
Normal file
@@ -0,0 +1,4 @@
|
|||||||
|
# This is the **HOMEPAGE**.
|
||||||
|
Refer to [Markdown](http://daringfireball.net/projects/markdown/) for how to write markdown files.
|
||||||
|
## Quick Start Notes:
|
||||||
|
1. Add images to the *images* folder if the file is referencing an image.
|
||||||
5
docfx_project/toc.yml
Normal file
5
docfx_project/toc.yml
Normal file
@@ -0,0 +1,5 @@
|
|||||||
|
- name: Articles
|
||||||
|
href: articles/
|
||||||
|
- name: Api Documentation
|
||||||
|
href: api/
|
||||||
|
homepage: api/index.md
|
||||||
BIN
menu-1768000-1502336.png
Normal file
BIN
menu-1768000-1502336.png
Normal file
Binary file not shown.
|
After Width: | Height: | Size: 4.0 KiB |
Reference in New Issue
Block a user