Skip to content

Simple package to share file on local network using nodes.

Notifications You must be signed in to change notification settings

DarkCode01/share

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

41 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

Share

Share is a packege to manage Node and can share files between Node in the same network.

Installation

If available in Hex, the package can be installed by adding share to your list of dependencies in mix.exs:

def deps do
  [
    {:share, "~> 0.1.0"}
  ]
end

Usage

Creation of a Node:

iex> {:ok, node_info} = Share.Node.create(name: "test", secret: :secret)
{:ok,
 %Share.Node{
   hostname: "localhost", # Your hostname
   name: "test",
   pid: #PID<x.x.x>,
   secret: :secret
 }} 

Connect with other Node:

iex> {:ok, list_others_nodes} = Share.Node.connect_node(name: "test", hostname: "localhost")
{:ok, [:"test@localhost"]}

Share a file:

iex> :ok = Share.send(to: :"test@localhost", filename: "/path/file")
Made with ❤️ by darkcoder.

About

Simple package to share file on local network using nodes.

Topics

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published

Languages