简体   繁体   English

gem从Rails应用程序将文件从ruby提交到git

[英]gem to commit files into git from ruby on rails application

Hey I am working on ruby on rails application where user can create set of instructions in the form of text. 嘿,我正在开发Rails应用程序上的ruby,用户可以在其中创建文本形式的指令集。 We have a requirement to save this text (dynamic) into git. 我们需要将此文本(动态)保存到git中。 Could someone suggest which is the best gem to achieve below: 有人可以建议以下哪个是最好的宝石:

  1. I have to push text into git as a zip folder. 我必须将文本作为zip文件夹推送到git中。
  2. I need to pull latest text from git to the UI. 我需要将最新文本从git拉到用户界面。
  3. If any conflicts, need to handle error messages. 如果有任何冲突,则需要处理错误消息。
  4. We need to show all the files available in git. 我们需要显示git中所有可用的文件。

Help would be appreciated :) 帮助将不胜感激:)

It seems the git fulfills your needs. git似乎满足了您的需求。 Keep in mind that the text and zip parts of your requirements has nothing to do with git so you should use other gems and/or standard library things to get your stuff into and out from zip files. 请记住,需求的文本和zip部分与git无关,因此您应该使用其他gem和/或标准库内容来将内容放入zip文件或从zip文件中取出。

To find a gem for something you can go to rubygems and type in what you need in the search field. 要查找某件宝石,可以转到rubygems,然后在搜索字段中键入所需的内容。 The result shows number of downloads which may be an indication of where to look further. 结果显示下载次数,这可能表明需要进一步查找。

声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM