Security News
tea.xyz Spam Plagues npm and RubyGems Package Registries
Tea.xyz, a crypto project aimed at rewarding open source contributions, is once again facing backlash due to an influx of spam packages flooding public package registries.
file-config-reader
Advanced tools
Readme
A simple module for reading and merging config files that are stored "locally" (current working tree) and "globally" (home directory).
This module was built primarily for use when writing command-line (CLI) programs in Node.js. It implements some features from a few of my favorite command-line applications:
Instead of passing options to the command-line, it's often beneficial to store program-specific options in a configuration file. Additionally, you may want to maintain project-specific configuration files and/or a global configuration file for shared cross-project settings (i.e. 'git'). Also, when working within subdirectories of a project folder, it's often useful for a command-line utility to search upwards in the directory tree for a configuration file, so you don't constantly need to navigate back to the location of the configuration file (i.e. JSHint).
Note: Currently, this module only supports files with JSON content.
npm install file-config-reader --save
> pwd
/Users/andre/dev/projects/cli_reader
> cat conf.json
{
"projectName": "cli_reader_sample",
"email": "no-reply@andregiannico.com"
}
> cat $HOME/conf.json
{
"firstName": "Andre",
"lastName": "Giannico",
"email": "andre@andregiannico.com",
age: 31
}
var FileConfigReader = require('file-config-reader');
var conf = new FileConfigReader('conf.json');
console.log(conf.firstName);
// output
"Andre"
console.log(conf);
// output
{
projectName: "cli_reader_sample",
firstName: "Andre",
lastName: "Giannico",
email: "no-reply@andregiannico.com",
age: 31
}
Copyright 2014 Andre Giannico MIT License (enclosed)
FAQs
A simple module for loading/merging local and global JSON configuration files.
The npm package file-config-reader receives a total of 1 weekly downloads. As such, file-config-reader popularity was classified as not popular.
We found that file-config-reader demonstrated a not healthy version release cadence and project activity because the last version was released a year ago. It has 1 open source maintainer collaborating on the project.
Did you know?
Socket for GitHub automatically highlights issues in each pull request and monitors the health of all your open source dependencies. Discover the contents of your packages and block harmful activity before you install or update your dependencies.
Security News
Tea.xyz, a crypto project aimed at rewarding open source contributions, is once again facing backlash due to an influx of spam packages flooding public package registries.
Security News
As cyber threats become more autonomous, AI-powered defenses are crucial for businesses to stay ahead of attackers who can exploit software vulnerabilities at scale.
Security News
UnitedHealth Group disclosed that the ransomware attack on Change Healthcare compromised protected health information for millions in the U.S., with estimated costs to the company expected to reach $1 billion.