Skip to content

Commit

Permalink
Melhorar mensagens de erro e configuração
Browse files Browse the repository at this point in the history
  • Loading branch information
ricardoborges committed Sep 8, 2016
1 parent 491f0b9 commit d76c7e4
Show file tree
Hide file tree
Showing 10 changed files with 27 additions and 7 deletions.
3 changes: 3 additions & 0 deletions src/GrammarIDE/GrammarIDE.csproj
Original file line number Diff line number Diff line change
Expand Up @@ -184,6 +184,9 @@
</BootstrapperPackage>
</ItemGroup>
<Import Project="$(MSBuildToolsPath)\Microsoft.CSharp.targets" />
<PropertyGroup>
<PostBuildEvent>xcopy "$(SolutionDir)..\lib\dot" "$(ProjectDir)bin\Debug\dot" /Y /I /E</PostBuildEvent>
</PropertyGroup>
<!-- To modify your build process, add your task inside one of the targets below and uncomment it.
Other similar extension points exist, see Microsoft.Common.targets.
<Target Name="BeforeBuild">
Expand Down
5 changes: 5 additions & 0 deletions src/GrammarIDE/Presenters/AstPresenter.cs
Original file line number Diff line number Diff line change
Expand Up @@ -78,6 +78,11 @@ private void CreateASTGraph(CommonTree commonTree)

var dotpath = string.Format("{0}\\dot.exe", Config.DotPath);

if (!Directory.Exists(Config.DotPath))
{
throw new Exception("Caminho da ferramenta dot.exe inválido.");
}

var gen = new DotTreeGenerator();
var dotgraph = gen.ToDot(commonTree);

Expand Down
2 changes: 1 addition & 1 deletion src/GrammarIDE/Presenters/ExecPresenter.cs
Original file line number Diff line number Diff line change
Expand Up @@ -127,7 +127,7 @@ public void Build()
ShowAsm(bytecode.Script);

MainPresenter.MainView.WriteLine();
MainPresenter.MainView.WriteOutput("Construído com sucesso");
MainPresenter.MainView.WriteOutput("Compilado com sucesso");

sourceMap = bytecode.SourceMap;
}
Expand Down
3 changes: 0 additions & 3 deletions src/GrammarIDE/Program.cs
Original file line number Diff line number Diff line change
Expand Up @@ -6,9 +6,6 @@ namespace GrammarIDE
{
static class Program
{
/// <summary>
/// The main entry point for the application.
/// </summary>
[STAThread]
static void Main()
{
Expand Down
2 changes: 1 addition & 1 deletion src/GrammarIDE/Views/Ast/AstForm.Designer.cs

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

3 changes: 3 additions & 0 deletions src/NPortugol.Tests/NPortugol.Tests.csproj
Original file line number Diff line number Diff line change
Expand Up @@ -139,6 +139,9 @@
<ItemGroup>
<Folder Include="Properties\" />
</ItemGroup>
<ItemGroup>
<Service Include="{82A7F48D-3B50-4B1E-B82E-3ADA8210C358}" />
</ItemGroup>
<Import Project="$(MSBuildToolsPath)\Microsoft.CSharp.targets" />
<!-- To modify your build process, add your task inside one of the targets below and uncomment it.
Other similar extension points exist, see Microsoft.Common.targets.
Expand Down
4 changes: 4 additions & 0 deletions src/Npc/App.config
Original file line number Diff line number Diff line change
@@ -0,0 +1,4 @@
<?xml version="1.0"?>
<configuration>

</configuration>
4 changes: 3 additions & 1 deletion src/Npc/Npc.csproj
Original file line number Diff line number Diff line change
Expand Up @@ -87,7 +87,9 @@
</ProjectReference>
</ItemGroup>
<ItemGroup>
<None Include="App.config" />
<None Include="App.config">
<SubType>Designer</SubType>
</None>
</ItemGroup>
<ItemGroup>
<Folder Include="Properties\" />
Expand Down
4 changes: 4 additions & 0 deletions src/TurboNPortugol/App.config
Original file line number Diff line number Diff line change
@@ -0,0 +1,4 @@
<?xml version="1.0"?>
<configuration>

</configuration>
4 changes: 3 additions & 1 deletion src/TurboNPortugol/TurboNPortugol.csproj
Original file line number Diff line number Diff line change
Expand Up @@ -142,7 +142,9 @@
<EmbeddedResource Include="Views\MainForm.resx">
<DependentUpon>MainForm.cs</DependentUpon>
</EmbeddedResource>
<None Include="App.config" />
<None Include="App.config">
<SubType>Designer</SubType>
</None>
<None Include="Exemplos\Bolha.ps">
<CopyToOutputDirectory>Always</CopyToOutputDirectory>
</None>
Expand Down

0 comments on commit d76c7e4

Please sign in to comment.