Coder Social home page Coder Social logo

example's People

Contributors

antonrademaker avatar augustoproiete avatar bjorkstromm avatar dannylloyd avatar devlead avatar edgardosreis avatar gep13 avatar nils-a avatar patridge avatar patriksvensson avatar philo avatar sierzput avatar

Stargazers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

Watchers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

example's Issues

Error running ./build.sh on Ubuntu - System.ComponentModel.Composition

On a fresh clone, running build.sh, I get the following error. What should be my next steps to deubg or otherwise resolve?

btomasini@btomasini-laptop02 ~/D/g/example> ./build.sh 
Could not load file or assembly or one of its dependencies.
System.IO.FileNotFoundException: Could not load file or assembly or one of its dependencies.
File name: 'System.ComponentModel.Composition, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089'
  at NuGet.CommandLine.Program.MainCore (System.String workingDirectory, System.String[] args) [0x000e3] in <845485c546924737a40430d80ba302fd>:0 
Could not restore NuGet packages.

Here is my config:

btomasini@btomasini-laptop02 ~/D/g/example> lsb_release  -a
No LSB modules are available.
Distributor ID: Ubuntu
Description:    Ubuntu 17.10
Release:        17.10
Codename:       artful
btomasini@btomasini-laptop02 ~/D/g/example> dotnet --version
2.1.401

Calling build.sh with -Target argument causes double targets

Due to -target=$TARGET $DRYRUN "${SCRIPT_ARGUMENTS[@]}", the script seems to pass both "Default" and the actual target argument of the call which then returns the following error:

Multiple arguments with the same name (Target).

This happened while running in a docker container from pomma89/dotnet-mono:dotnet-3-mono-5-sdk which runs some version of Debian I believe and the simple call

RUN ./build.sh -Target=Clean

.

build.sh should use the .Net Core cli command first and fall back to mono in its absence

With .Net Core being available on Linux and macOS systems without the need for mono to be present, as well as various Docker containers being provided by Microsoft (and others) that are utilizing .Net Core on Alpine without mono, the build.sh script should take these into account and set the dotnet command accordingly. This will allow greater portability and usability of the default script.

Running target issue

Please, could you help me to understand: I defined default target "Report", but when I run the script (see below) Powershell shows error:
image

var target = Argument("Target", "Report");

Task("Start")
  .Does(() =>
{
  Information("Hello World!");
});

Task("Tests")
    .IsDependentOn("Start")
    .Does(()=>
{
    Information("Tests!");
});

Task("Report")
    .IsDependentOn("Tests")
    .Does(()=>
{
    Information("Report!");
});

RunTarget(target);

Update build.ps1?

It looks like this build.ps1 file is getting out of sync with the latest version?

build.ps1: Could not load file or assembly Microsoft.Build

This has now happened on two different PCs, both running Windows 10 with VS 2017 installed.

Also:
NuGet Version: 3.5.0.1938
MsBuild Version: 4.6.1586.0

Preparing to run build script...
Running build script...
Analyzing build script...
Processing build script...
Installing tools...
Downloading and installing Roslyn...
Installing packages (using https://packages.nuget.org/api/v2)...
Copying files...
Copying Roslyn.Compilers.CSharp.dll...
Copying Roslyn.Compilers.dll...
Deleting installation directory...
Compiling build script...

========================================
Clean
========================================
Executing task: Clean
Creating directory C:/Users/rickysmith/Documents/Projects/cake-example/src/Example/bin/Release
Finished executing task: Clean

========================================
Restore-NuGet-Packages
========================================
Executing task: Restore-NuGet-Packages
Failed to load msbuild Toolset
  Could not load file or assembly 'Microsoft.Build, Version=14.0.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a' or one of its dependencies. The system cannot f
ind the file specified.
An error occurred when executing task 'Restore-NuGet-Packages'.
Error: NuGet: Process returned an error (exit code 1).

Hello World Example Generates Warnings

What You Are Seeing?

unknown.cake (1595,43): Cake.Common.Xml.XmlPokeAliases.XmlPoke(this Cake.Core.ICakeContext, string, string, string)' is obsolete:Please use XmlPokeString(string, string, string) instead.'
unknown.cake (1602,43): Cake.Common.Xml.XmlPokeAliases.XmlPoke(this Cake.Core.ICakeContext, string, string, string, Cake.Common.Xml.XmlPokeSettings)' is obsolete:Please use XmlPokeString(string, string, string, XmlPokeSettings) instead.'
unknown.cake (1725,45): Cake.Core.Scripting.IScriptHost.Setup(System.Action)' is obsolete:Please use Setup(Action) instead.'
unknown.cake (1726,47): Cake.Core.Scripting.IScriptHost.Teardown(System.Action)' is obsolete:Please use Teardown(Action) instead.'

What is Expected?

No warnings

What version of Cake are you using?

Cake.0.11.0.

Are you running on a 32 or 64 bit system?

64 bit

What environment are you running on? Windows? Linux? Mac?

Mac

Are you running on a CI Server? If so, which one?

No

How Did You Get This To Happen? (Steps to Reproduce)

Followed Hello World Example

Output Log

https://gist.github.com/brock555/0477e86600222b751d84b5da2312a593

Cake.Json addin problem with Cake.Build 0.22.2

I'm experiencing a problem with Cake.Build 0.22.2 and using the Cake.Json addin.
If I'm trying to build the actual example repository after adding #addin Cake.Json into the build.cake script, I get the following error:

Compiling build script...
Error: Error occurred when compiling build script: error CS0246: The type or namespace name 'Newtonsoft' could not be fo
und (are you missing a using directive or an assembly reference?)
(2431,8): error CS0246: The type or namespace name 'Newtonsoft' could not be found (are you missing a using directive or
 an assembly reference?)
(2437,8): error CS0246: The type or namespace name 'Newtonsoft' could not be found (are you missing a using directive or
 an assembly reference?)
(2433,12): error CS0012: The type 'JObject' is defined in an assembly that is not referenced. You must add a reference t
o assembly 'Newtonsoft.Json, Version=9.0.0.0, Culture=neutral, PublicKeyToken=30ad4fe6b2a6aeed'.
(2439,12): error CS0012: The type 'JObject' is defined in an assembly that is not referenced. You must add a reference t
o assembly 'Newtonsoft.Json, Version=9.0.0.0, Culture=neutral, PublicKeyToken=30ad4fe6b2a6aeed'.

The workaround I'm using is stick to version 0.21.1 and use #addin nuget:?package=Cake.Json&version=1.0.2.13

Make this project build using PowerShell 2.0

The new plan going forward is to always update this projects bootstrapper when changes are made to the bootstrapper in the resources repository. In order to keep compatibility with PowerShell 2.0, I think it makes a lot of sense to force our AppVeyor build to use version 2 of PowerShell. That way, if the build fails, we know we have broken something.

Thoughts @devlead

build.sh downloads old version of nuget

lots of things just don't work with the nuget 2.8 that's downloaded.

I fixed many issues by actually downloading this version from build.sh

https://dist.nuget.org/win-x86-commandline/v3.4.4/NuGet.exe

I'm not sure if there's a better url to download a 'mono' version of NuGet, but the 2.8 version currently won't cut it for several scenarios

(Maybe a better issue on nuget repo)

Doesn't work on macos

[karl@MacBook-Pro-2:Devel]$ git clone https://github.com/cake-build/example.git
Cloning into 'example'...
remote: Counting objects: 186, done.
remote: Compressing objects: 100% (3/3), done.
remote: Total 186 (delta 0), reused 0 (delta 0), pack-reused 182
Receiving objects: 100% (186/186), 35.79 KiB | 0 bytes/s, done.
Resolving deltas: 100% (76/76), done.
Checking connectivity... done.
[karl@MacBook-Pro-2:Devel]$ cd example/
[karl@MacBook-Pro-2:example(master)]$ ls
LICENSE		appveyor.yml	build.ps1	src
README.md	build.cake	build.sh	tools
[karl@MacBook-Pro-2:example(master)]$ ./build.sh 
Downloading NuGet...
Feeds used:
  /Users/karl/.local/share/NuGet/Cache
  https://api.nuget.org/v3/index.json

Restoring NuGet package Cake.0.17.0.
WARNING: Unable to find version '0.17.0' of package 'Cake'.
  /Users/karl/.local/share/NuGet/Cache: Package 'Cake.0.17.0' is not found on source '/Users/karl/.local/share/NuGet/Cache'.
  https://api.nuget.org/v3/index.json: Unable to load the service index for source https://api.nuget.org/v3/index.json.
  /tmp/unity-monodevelop-monoframework-4.0.5/lib/libMonoPosixHelper.dylib
  /tmp/unity-monodevelop-monoframework-4.0.5/lib/libMonoPosixHelper.dylib

Could not find Cake.exe at '/Users/karl/Devel/example/tools/Cake/Cake.exe'.

build.ps1 not executing

Hi,

I've tried to execute build.ps1, following the "Getting started" page (http://cakebuild.net/docs/tutorials/getting-started).

It seems to fail on line 50 of build.ps1. First error being:
"Join-Path : cannot bind argument to parameter 'Path' because it is null.

Writing
$TOOLS_DIR = Join-Path $PS_Script_Root "tools"
instead of
$TOOLS_DIR = Join-Path $PSScriptRoot "tools"
allowed the script to execute.

I don't know about powershell or cake, but it looks like it is just the underscores missing, right ?

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.