How to use the @truffle/config.getUserConfig function in @truffle/config

To help you get started, we’ve selected a few @truffle/config examples, based on popular ways it is used in public projects.

Secure your code as it's written. Use Snyk Code to scan source code in minutes - no build needed - and fix issues immediately.

github trufflesuite / truffle / packages / core / lib / services / analytics / google.js View on Github external
/**
 * @module googleAnalytics;
 * @requires module:@truffle/config
 * @requires module:universal-analytics
 * @requires module:uuid
 * @requires module:inquirer
 * @requires module:../version
 */

const Config = require("@truffle/config");
const userConfig = Config.getUserConfig();
const ua = require("universal-analytics");
const uuid = require("uuid/v4");

const inquirer = require("inquirer");

const version = require("../../version").info();

//set truffleAnalyticsId depending on whether version is bundled
const truffleAnalyticsId = version.bundle ? "UA-83874933-6" : "UA-83874933-7";

const analyticsInquiry = [
  {
    type: "list",
    name: "analyticsInquiry",
    message:
      "Would you like to enable analytics for your Truffle projects? Doing so will allow us to make sure Truffle is working as expected and help us address any bugs more efficiently.",

@truffle/config

Utility for interacting with truffle-config.js files

MIT
Latest version published 1 year ago

Package Health Score

53 / 100
Full package analysis