Git Product home page Git Product logo

Comments (6)

micprog avatar micprog commented on August 21, 2024

The import feature in bender requires a mapping to be defined to include parts of the upstream repository into your project. The repository is cloned into a temporary location, and the needed files are copied over afterwards, so it makes sense that you cannot find the repository.
Try adding the --refetch flag to the bender import command, as this will trigger the proper update of your files. Otherwise bender will attempt to print a diff between the files included in your repository and those in the upstream, and here it cannot find the needed directory.
If this fixes the issue, I will update the documentation, errors, and code to provide a bit better user experience for this feature.

from bender.

znaky avatar znaky commented on August 21, 2024

Thanks @micprog,
Adding the --refetch flag did the trick. When I run bender import without the --refetch it throws the error below;

error: Cannot startup runtime. No such file or directory (os error 2)

But, when I use --refetch for the same Bender.yml file, it works perfectly.

from bender.

znaky avatar znaky commented on August 21, 2024

Follow up question, Is there an easy way to get all the files in that repo without listing all of the files in the mapping? I tried using * like below, but unfortunately, it didn't work.

    mapping: 
      - {from: '*', to: '*' }

from bender.

micprog avatar micprog commented on August 21, 2024

You can link directories, so you could try and give '.' a shot, but I haven't tested that yet. It might make sense to by default clone the full repository if no mapping is provided, but that is not implemented yet.

from bender.

znaky avatar znaky commented on August 21, 2024

It might make sense to by default clone the full repository if no mapping is provided

I agree.

I tested '.' , folder_layer1 and folder_layer1/folder_layer2/last_folder cases and only the last one is working. i.e. it cannot link recursively. Maybe, linking recursively can be another feature that may be added in the future releases.

Thanks again

from bender.

znaky avatar znaky commented on August 21, 2024

Found it. If I do it like below, it works. But, it still throws an error and looks like skips the .txt files. Interesting.

    mapping: 
      - {from: '', to: '' }
error: Cannot startup runtime. No such file or directory (os error 2)

from bender.

Related Issues (20)

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.