Questions tagged [generate]

Any question related to the Generate developer framework and CLI tool should tagged using the `generate` tag. How to use the generate CLI to run this generator ? How to use this generator as a plugin ? How to run a task from a subgenerator ? How to create my own Generate generator ?

What is generate ?

Generate is an extremely modern command line tool and developer framework for scaffolding out any kind of developer projects. Generate offers the robustness and configurability of Yeoman, the expressiveness and simplicity of Slush, and more powerful flow control and composability than either.

It is an open source framework hosted on github under the MIT license.

It has its own Github organization to namespace all the generators authored by the same author, Jon Schlinkert.

Generate is part of the awesome node toolkit created by the same author: https://github.com/node-toolkit

Some of the best related projects composing the node-toolkit:

Related StackOverflow tags

371 questions
2
votes
2 answers

VHDL 2008: Index in external names containing generated instances

For a testbench, I'm trying to use external names to read signals within a DUT. It is not desired to export these signals outside of the DUT, so I concluded that using external names was the best option here. Unfortunately, there are some for…
2
votes
1 answer

How do I generate Matrix with sum of every individual row and column being zero

I need to generate a matrix where the diagonal are zeroes and every column and row has a sum of zero. For example first row 0, 4, -2, -1, 1 = sum is 0 or the first column 0, -4, 2, 1, 1 = sum is 0 This works for every column and row of course 0, 4,…
Arriburi
  • 21
  • 3
2
votes
1 answer

Build only specific pages in Nuxt.js

Is it possible to build or generate only specific pages from a Nuxt project? In other words, a subset of the project. In example, let's say I have the following pages directory: pages/ | |- index.vue |- about-us.vue |- pricing.vue |- moduleA | …
elielr01
  • 66
  • 2
  • 8
2
votes
3 answers

How to get the month and year from the past date untill now JavaScript

I'm trying to figure out how to get combinations of year and month from the past date up till now. So lets say, the past date is given as const date = "December 2019" Then I need an array const arrayOfMonths = [ "April 2020", "March 2020",…
Yukichka
  • 144
  • 2
  • 9
2
votes
1 answer

Generate random records from the table tblFruit based on the field Type

I will need your help to generate random records from the table tblFruit based on the field Type (without no duplication) As per the above table. There are 4 type of fruit number 1,2,3,4 I want to generate x records dynamically from the table…
Tairon
  • 39
  • 6
2
votes
1 answer

`define in generate if statement

This generates single bit out, for all values of parameter syn. Why for syn>0 its not generating 2 bit out module test (clk, rst_n, en, rst_n2, in, out ); parameter syn=0; generate…
2
votes
3 answers

How does this function work "abcdefghijklmnopqrstuvwxyz" [rand()%26]?

To generate random letters of the alphabet "abcdefghijklmnopqrstuvwxyz" [rand()%26] How does this work?
leon
  • 165
  • 2
  • 10
2
votes
1 answer

How to generate a cone in 3D Numpy array

I'm a master student in my thesis year and I need to inject geometric holes in a 3D model. This code made by the author of both pymrt and raster_geometry, norok2, was of great help to generate spheres: import numpy as np def sphere(shape, radius,…
2
votes
4 answers

Python: How to generate list with items repeating in two lists

I have two lists of items: list_1 = ['A', 'B', 'C', 'C', 'D'] list_2 = ['C', 'C', 'F', 'A', 'G', 'D', 'C'] I want to create a new list with the elements that are in the two lists. Like this: ['A', 'C', 'C', 'D'] Notice that it should take in mind…
Lzhelis
  • 41
  • 1
  • 6
2
votes
2 answers

Symfony 4 after generating user via make:user schema update crashed

I am trying make user via CLI: (symfony doc) php bin/console make:user This command create User.php entity which implements UserInterface. But after command: php bin/console doctrine:schema:update --force I get errors: In AbstractMySQLDriver.php…
Lajdák Marek
  • 2,969
  • 8
  • 29
  • 58
2
votes
0 answers

Nuxt.js generate page with dynamic URL

My nuxtjs app contains page with dynamic url (actually page has two params event-slug and event-id), then in that page's asyncData method, I extract these params from URL and use for axios request. This page opens when I click on one item on list of…
user11273740
2
votes
2 answers

How to go:generate stringer constants from multiple packages?

I have a struct like this: .foo/bar/constants.go .foo/constants.go .main.go In main.go I declare the type: package agepack type EventType uint //go:generate stringer -type EventType const ( FirstType EventType iota SecondType …
Magestro
  • 34
  • 5
2
votes
1 answer

How can I stop Maven from regenerating something if the generation-source has not changed?

I want maven to skip generation of something (source, XML, XSDs - you name it - ) if the source of that thing has not changed. Something like - IF the all files in src/main/x are younger than all files in target/generated-sources - THEN skip…
Inquisitor Shm
  • 1,433
  • 5
  • 17
  • 26
2
votes
0 answers

Load a Random background video on load without repeating same video

I've been working on this homepage background video for quite a while and always try to tinker with it to make it better. I just did a test and it took 37 page refreshes to load each of my 12 videos at least once. I stopped when I had finally seen…
2
votes
1 answer

How to create temporary link for the new user account?

I created single page app that requires username and password for users authentication. Each account in the system is created by administrators. There is no option for user to click on the link and create account. After researching and looking for…
espresso_coffee
  • 5,980
  • 11
  • 83
  • 193
1 2
3
24 25