Giter Site home page Giter Site logo

just-use-the-source's Introduction

Just Use the Source

Are you tired of dependency hell? Are you tired of having to import a library just to use a one-liner function? Do you wish you could just share a piece of useful code simply and easily, without worrying about versions, documentation, etc.? If so, you've come to the right place!

The purpose of this repository is to encourage the sharing and reuse of simple pieces of code, without having to rely on complex infrastructure for managing dependencies. The idea is really simple: for small(ish) pieces of code, that are not expected to evolve in the future, it sometimes makes more sense to just copy the code into your project, rather than include it as a dependency.

Licensing

The "just use the source" ethic encourages, but does not mandate, the release of code to the public domain. You might want to choose some other license that better fits your needs and requirements. I am not a lawyer.

How to Share Your Code

  1. Put your amazingly useful code in a single file.
  2. Include license information, and a repository URL in your code.
  3. Add license information and adequate documentation.
  4. Include a "Just use the source" comment in your code.
  5. Publish your code on GitHub, GitLab or wherever.

Here's a sample source code file that follows the "just use the source" ethic:

# This code is released to the public domain (2023).
# Author: Sharon Rosner
# https://github.com/digital-fabric/just-use-the-source
#
# Just use the source: copy this file into your project, and use it as you wish.

# Implements a greeter class
class Greeter
  # Initializes a greeter with the given name.
  #
  # @param name [String] name to be greeted
  def initialize(name)
    @name = name
  end

  # Prints a greeting to STDOUT
  #
  # @return [Greeter] self
  def greet
    puts "Hello, #{@name}!"
    self
  end
end

How to Just Use the Source

  1. Read the code and look for a "Just use the source" mention.
  2. Make sure the license information meets your use case.
  3. Copy the code into your project.
  4. That's all there is to it.

just-use-the-source's People

Contributors

noteflakes avatar

Watchers

 avatar  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.