[bisq-network/bisq-docs] Building this on Windows (#56)

oculushut notifications at github.com
Sun May 20 12:45:40 UTC 2018


***Problem I had***

Could be a "user error", but in case anybody else is trying to use build this on a Windows box and encountering the same when trying to build:

```
Failed to capture snapshot of input files for task ':asciidoctor' property 'sourceDir' during up-to-date check.
> Failed to create MD5 hash for file content.
```

***Environment***

This was on an environment using Windows box + PowerShell 3 and then [scoop ](https://scoop.sh/)to install gradle and then the gradle plugin for asciidoctor [plugin for gradle](https://github.com/asciidoctor/asciidoctor-gradle-plugin) to build the [asciidoctor files](https://asciidoctor.org/docs/user-manual/) which the documentation uses... the result is a bunch of html files translated from the asciidoctor files compiled and saved inside the default build directory for asciidoctor (./build/asciidoctor)...

***Fix***

To get around it, I just went one level above the root project file (where I git cloned this project) and created a new gradle build file and then ran **gradle build** in PowerShell from here:

```
plugins {
    id 'org.asciidoctor.convert' version '1.5.7'
}

asciidoctor {
    sourceDir = file('./bisq-docs')

    resources {
        from(sourceDir) {
            include '**/*.png'
            exclude 'build/**'
        }
    }

    attributes 'source-highlighter': 'coderay',
        icons               : 'font',
        idprefix            : '',
        idseparator         : '-',
        docinfo1            : ''
}

build.dependsOn asciidoctor
```
This worked for me... changed the sourceDir to the location of the project.

**Why did it happen and future fix?**

I am not sure.  Not very familiar with Gradle, asciidoctor or scoop so not really qualified to say exactly what the problem was!  Perhaps somebody else can clarify if this was a red herring, but I read an article suggesting that Windows may have some kind of locking mechanism which stops the part of the build job where it tries to hash the directory to check for updates from working.  It's a [2015 article](https://discuss.gradle.org/t/build-failure-with-failed-to-capture-snapshot-of-input-files-for-task-war-during-up-to-date-check/9132/6) so may be wrong...

Anyhow, if this was the issue then could just move all of the files asciidoctor uses into a subdirectory and leave the gradle.build file where it is... or perhaps there is a parameter or way to specify the build in gradle which overcomes what I encountered.


-- 
You are receiving this because you are subscribed to this thread.
Reply to this email directly or view it on GitHub:
https://github.com/bisq-network/bisq-docs/issues/56
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.bisq.network/pipermail/github/attachments/20180520/0d2087aa/attachment.html>


More information about the github mailing list