I'm building a custom yeoman generator, so when it's time to create files they're created one directory above my current location, or at .., so for example if I run:
yo koala
From /home/diegoaguilar/koala the files will be created at /home/diegoaguilar. How am I supposed to tell the path where the generator should copy files? I really thought that would be process.cwd() or simply where yeoman generator is being ran from.
This is the code I got for files generation:
  writing: {
    app: function () {
      this.fs.copyTpl(
        this.templatePath('_package.json'),
        this.destinationPath('package.json'),
        {appname: this.appname}
      );
      this.fs.copy(
        this.templatePath('_bower.json'),
        this.destinationPath('bower.json')
      );
    },
    projectfiles: function () {
      this.fs.copy(
        this.templatePath('editorconfig'),
        this.destinationPath('.editorconfig')
      );
      this.fs.copy(
        this.templatePath('jshintrc'),
        this.destinationPath('.jshintrc')
      );
    }
  },