Giter Site home page Giter Site logo

perl6-config-netrc's Introduction

NAME

Config::Netrc - module for parsing of Netrc configuration files.

SYNOPSIS

use Config::Netrc;
say Config::Netrc::parse-file('my-example.netrc');

DESCRIPTION

There are basically two main functions: parse and parse-file. First function takes a string of netrc-file content and returns to you a hash with some signature or Nil value if parser failed.

This hash contains of two arrays: comments and entries. In the section comments you will get all comment strings(without leading #) and in the entries section you get array of hashes with this structure:

machine  => {value => val, comment => my-comment},
login    => {value => val, comment => my-comment},
password => {value => val, comment => my-comment}

Of course, login or password lines are optional and comment entry for lines like following:

machine val # my-comment

is also optional.

You will be able to use this hash to determine state of user's Netrc file state.

TODO

  • Detection of user's config file at his home directory

COPYRIGHT

This library is free software; you can redistribute it and/or modify it under the terms of the Artistic License 2.0

perl6-config-netrc's People

Stargazers

 avatar

Watchers

 avatar  avatar

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.