Proposal and Validation of Git Compile

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



Hello,

I'm writing to propose and get a validation of one of the ideas I had for git tool. 
Background:
We are currently able to clone the complete repository and access the code. Why don't we allow only part of the code maybe a few lines to be imported into the repository?

Issues:
- Developers have duplicate code within which could be a utility file and some repositories have whole sets of codes like the Algorithms repository. We would only require a particular algorithm from that repository, in those cases, there isn't an easy way to import that snippet.
- A large amount of similar duplicate codes are written by authors in different personal projects like utilities. These must be made reusable. Eg: Code on a gist is copied into every repository, why not create and use the gist itself as it also has versioning?

Idea:
- Specify a syntax which specifies how to import the gist or snippet
- When creating the file use the syntax to import the snippet
- Users need to compile the new file to resolve the snippet but the decompiled version with the syntax is retained in the cache
- When the user pushes the file use the decompiled version but not the compiled version so that the git hosted on the server can make references between repositories and gists
- When another user pulls the decompiled file, the file is compiled as part of git pull and resolved in the remote reference with the snippet so the user can run the code.


Issues:
Syntax might not be recognized by editors
Trust external author's code in production

I have attached the workflow below

I would like to know if there is a better way to solve this issue and avoid code duplication as I have limited knowledge of git.

Thank You

With Regards
Bhargav

Attachment: working.jpeg
Description: JPEG image


[Index of Archives]     [Linux Kernel Development]     [Gcc Help]     [IETF Annouce]     [DCCP]     [Netdev]     [Networking]     [Security]     [V4L]     [Bugtraq]     [Yosemite]     [MIPS Linux]     [ARM Linux]     [Linux Security]     [Linux RAID]     [Linux SCSI]     [Fedora Users]

  Powered by Linux