npm package discovery and stats viewer.

Discover Tips

  • General search

    [free text search, go nuts!]

  • Package details

    pkg:[package-name]

  • User packages

    @[username]

Sponsor

Optimize Toolset

I’ve always been into building performant and accessible sites, but lately I’ve been taking it extremely seriously. So much so that I’ve been building a tool to help me optimize and monitor the sites that I build to make sure that I’m making an attempt to offer the best experience to those who visit them. If you’re into performant, accessible and SEO friendly sites, you might like it too! You can check it out at Optimize Toolset.

About

Hi, 👋, I’m Ryan Hefner  and I built this site for me, and you! The goal of this site was to provide an easy way for me to check the stats on my npm packages, both for prioritizing issues and updates, and to give me a little kick in the pants to keep up on stuff.

As I was building it, I realized that I was actually using the tool to build the tool, and figured I might as well put this out there and hopefully others will find it to be a fast and useful way to search and browse npm packages as I have.

If you’re interested in other things I’m working on, follow me on Twitter or check out the open source projects I’ve been publishing on GitHub.

I am also working on a Twitter bot for this site to tweet the most popular, newest, random packages from npm. Please follow that account now and it will start sending out packages soon–ish.

Open Software & Tools

This site wouldn’t be possible without the immense generosity and tireless efforts from the people who make contributions to the world and share their work via open source initiatives. Thank you 🙏

© 2024 – Pkg Stats / Ryan Hefner

cripter

v1.0.1

Published

Servicio de encriptado, cli.

Downloads

4

Readme

Cripter

Proyecto para Encriptar y desencriptar archivos.

Instalar el módulo de manera global.

npm install cripter -g

Cómo usar.

Mostrar la ayuda del módulo.

cripter --help

Salida

Usage: commands [options] [command]

Servicio de Encriptado

Options:
  -V, --version   output the version number
  -h, --help      display help for command

Commands:
  add|a           Aumentar una Opción
  find|f <id>     Buscar una opción
  update|u <_id>  Actualizar una opción
  remove|r <_id>  Borrar una opción
  list|l          Listar las opciones
  apply|go <_id>  Aplica el encriptado de una Opción, según sea el formato de tipo que se le aplique.
  help [command]  display help for command

Configuraciones

Formato de Opción

{
  "id": "origen1",
  "origen":  "/usr/rutaOrigen/original_1.json",
  "destino": "/usr/Proyecto /.../rutaDestino/destino_1.crt",
  "tipo": "json"      // text(Texto) , fun (Funciones)
}

Configurar las Rutas

cripter add 

Actualizar Rutas

cripter update <id_Opcion>

Aplicar una Opción

cripter apply <id_Opcion>
// Opcional u
cripter go -id origen1

Aplicar Todas las opciones

cripter apply 0
cripter go 0

Uso en el cliente

Cómo usar el Servicio de criptografía en un proyecto:

Iniciamos un proyecto nuevo

 npm init -y

Creamos un proyecto, Suponiendo que el archivo "encriptado" se encuentra en el directorio actual:

 cp ./encriptado  /usr/proyecto/archivos
 cd /usr/proyecto
 npm init -y
 npm install cripto --save
 touch index.js

en el archivo index.js

const path = require('path')
const { cripto } = require('cripto')

// Obtenemos la Ruta Normalizada de /archivos/encriptado
const uri = path.normalize(__dirname+"/archivos/encriptado")

// Lee y desencripta el contenido a Json
var json = cripto.fileToJson(uri)

// Lee y desencripta el contenido a Texto plano
var text = cripto.fileToText(uri)

// lee y Desencripta el contenido a Función Ejecutable de Javascript
// El Archivo Original debería contenes UNA función.
// POR EJEMPLO:
/**
 * ()=>{
 * return ({
 *   mensaje: (arg) => console.log(arg)
 * })
 * } 
 *
*/ }
var func = cripto.fileToFun(uri)
func().mensaje("Parámetro para la función Mensaje");