Follow

Keep Up to Date with the Most Important News

By pressing the Subscribe button, you confirm that you have read and are agreeing to our Privacy Policy and Terms of Use
Contact

ls shows file, but nothing else can see it

I’m trying to run a nuget pack and push with a .nuspec file in a GitHub action, but nuget can’t seem to find the file.

I’ve added a pwd, an ls, and a cat to try to debug the issue, but it seems that not even the cat can see it.

From my workflow file:

MEDevel.com: Open-source for Healthcare and Education

Collecting and validating open-source software for healthcare, education, enterprise, development, medical imaging, medical records, and digital pathology.

Visit Medevel

pwd
ls artifacts/*

NUSPEC_NAME=${{ matrix.nuspec }}
cat artifacts/${NUSPEC_NAME}

(I also have a previous run where I echoed matrix.nuspec, and it does have just the file name JsonSchema.Net.es.nuspec.)

Output:

/home/runner/work/json-everything/json-everything
JsonSchema.Net.es.nuspec
es
cat: artifacts/JsonSchema.Net.es.nuspec: No such file or directory

Maybe I’m crazy, but it seems that since ls artifacts/* is outputting

JsonSchema.Net.es.nuspec
es

(es is a folder) then the file artifacts/JsonSchema.Net.es.nuspec actually does exist. So why isn’t cat seeing it?

I’ve been banging my head against this for a couple hours, and my brain is tired. Once I figure this out, I think the nuget commands will fall into place.

>Solution :

I would advise you to show everything you have on your system, using the simple command:

find . -ls

The -ls switch will make sure all information is shown, like file type, file or directory, …, and using that information you might solve your issue.

In case the situation is not clear yet, please edit your question, adding the result of the find command.

Add a comment

Leave a Reply

Keep Up to Date with the Most Important News

By pressing the Subscribe button, you confirm that you have read and are agreeing to our Privacy Policy and Terms of Use

Discover more from Dev solutions

Subscribe now to keep reading and get access to the full archive.

Continue reading