Particle compile output truncated

I am moving a project onto Photon which contains many separate .cpp files. I have set up a project structure including libraries. When I run “particle compile photon”, the compilation stops due to an error in the code, but the compiler output with the error is not shown.

Is there a way to get all of the compiler output?

For example, here the error stopping compilation is not shown.

particle compile photon

attempting to compile firmware

In file included from src/ui.cpp:4:0:
lib/Adafruit_SSD1305/src/Adafruit_SSD1305.h: In constructor ‘Adafruit_SSD1305::Adafruit_SSD1305(int8_t, int8_t, int8_t, int8_t)’:Compile a source file, or directory using the cloud compiler
Usage: particle compile [options] [files…]

I guess your particle compile photon command does not upload all the required files.
You could try particle compile photon . (the dot stands for current directory - including all source files).

With “bigger” projects it’s advisable to setup a proper project via particle project create and then import libraries via particle library add or particle library copy.

It turns out that the problem was something to do with stderr and stdout flushing from the particle CLI tool.

Compiling like this seems to fix the problem and show me all of the compiler output:

particle compile photon 2>&1 | cat