Ruby China
  • 社区
  • 招聘
  • Wiki
  • 酷站
  • Gems
  • 注册
  • 登录
Andersen Fan
@as181920
高级会员
第 2511 位会员 / 2012-06-13

[email protected]
上海
86 篇帖子 / 872 条回帖
13 关注者
8 正在关注
205 收藏
GitHub Public Repos
  • openai_api_proxy 1

    openai api client

  • appimage.github.io 0

    Given an URL to an AppImage, the GitHub action in this project inspects the AppImage and puts it ...

  • rl_learning 0

  • TencentMeeting-AppImage 0

  • Feishu-AppImage 0

    飞书AppImage打包

  • omni_region 0

  • natural_language_proce... 0

  • deep_learning_from_scr... 0

  • diffusers-ruby-demo 0

  • omni_article 0

More on GitHub
  • 概况
  • 话题
  • 回帖
  • 收藏
  • 正在关注
  • 关注者
  • Rails 应用的部署管理 at 2022年08月13日

    这边一直是这么干的,所有部署全部是 production env。走 cap 的 linked_file 文件(并转化成 ENV 参数),来区分不同环境需要的不同配置。

     class Application < Rails::Application
        config.before_configuration do
            env_file = Rails.root.join("config/local_env.yml")
            YAML.load_file(env_file, aliases: true)[Rails.env].to_h.each do |key, value|
              ENV[key.to_s] = value.to_s
            end if File.file?(env_file)
          end 
    end
    
  • 关于聚合支付 at 2022年03月23日

    这是汇付天下的产品吧,我去了解了解

  • 关于聚合支付 at 2022年03月22日

    最近遇到分账需求,调研了一下费用普遍过高,不适合中小商家使用,目前考虑单独对接微信&支付宝。

    在这两大平台提供原生分账能力的情况下,不清楚现在聚合支付机构收取那么高的年费是基于什么缘故(涉及分账就贵,牌照虽然贵,另外没牌照走银行托管账户方案的也贵)。

  • 请教:Rails7 中 form_with 中的 submit 的 data-disable-wtih 不起作用 at 2022年01月17日
    / fix disable_with on link and submit inside turbo-frame
    Rails.delegate(document, Rails.linkDisableSelector,   "turbo:before-cache", Rails.enableElement)
    Rails.delegate(document, Rails.buttonDisableSelector, "turbo:before-cache", Rails.enableElement)
    Rails.delegate(document, Rails.buttonDisableSelector, "turbo:submit-end", Rails.enableElement)
    Rails.delegate(document, Rails.formSubmitSelector, "turbo:submit-start", Rails.disableElement)
    Rails.delegate(document, Rails.formSubmitSelector, "turbo:submit-end", Rails.enableElement)
    Rails.delegate(document, Rails.formSubmitSelector, "turbo:before-cache", Rails.enableElement)
    
    
  • Foreman 是干什么的? 为什么不用 systemd ? at 2021年10月15日

    按时间顺序,foreman 确实在 systemd 成熟之前,(那时候生产很多用 monit,sidekiq 还是自带 daemon,终于等到 systemd 成熟 sidekiq 等库在新版设计时候也去掉了自身的 daemon 机制,推荐用系统自带的机制);

    linux 从原来的 init 机制,争议 systemd 是否管太多,切换到 systemd,再 systemd 支持 user level unit 等逐渐成熟,这个过程前有很多其它 daemon 方案,现在生产用 systemd 应该比较成熟了 (用容器是另一套方案)

    foreman 方便本地开发(我本地会用),方便一键启关联服务,避免多终端看日志不方便等,好像 rails 7 默认的./bin/dev 执行的就是 forman start

  • Ruby China 社区里全栈工程师的具体定义是什么 at 2021年10月15日

    干后端,兼上运维,兼上前端,略搞产品设计,完了找人指点建议,人说该补上销售技能。

  • [上海][2021-07-20] Ruby 聚会召集 at 2021年07月12日

    没意外事项就过来

  • 使用 Turbo 处理 modal 弹框和下拉加载的方法和遗留问题 at 2021年06月28日

    刚手动调试,监听 scroll 判断后,js 主动把下一个 turbo_frame 的 loading 设置为 eager 是可行的(再下一个依旧是 lazy load,同样逻辑页面到一定位置后修改为 eager)。

  • 妈妈再也不用担心我忘记更新 SSL 证书了 at 2021年06月28日

    使用 Let's encrypt 及子域名泛解析的话,要自动更新证书需要联动 dns 解析 api 才能完成验证吧

  • 微信支付 RubyGem 发布 - 适用于微信支付 V3 接口 at 2021年05月14日

    官方产品接口有些还停留在 V2,包括企业支付。 https://pay.weixin.qq.com/wiki/doc/apiv3/index.shtml

  • 微信支付和支付宝不支持 ruby 语言的 SDK?大家都是平常用的什么解决方案还是自己写? at 2021年05月12日

    自己写(了个 engine),抄袭了相关 gem 的加解密

  • 敏感词过滤实现 at 2021年05月11日

    公安备案平台上有词库下载

  • 敏感词过滤实现 at 2021年05月11日

    看到一个类似的:https://github.com/gonzedge/rambling-trie

  • 微信开发者工具 Linux 版 at 2020年08月18日

    本机常规终端开启,不走 ssh/tmux 等试试

  • 各位大佬,离职证明很重要吗? at 2019年11月04日

    1,重要 2,开离职证明是公司义务,受到影响甚至可以索赔。 3,补偿和证明是两回事,互不影响

  • 二维码缺失,有什么办法修复吗? at 2019年10月25日

    扫出来地址,重新生成一个就好了。

  • Rails 视图层? at 2018年08月21日

    单纯要实现功能用一把梭真的依旧很爽,如果有技术偏好或者非功能需求,再考虑改架构设计。

  • 10.13-14 郑州见 at 2018年08月13日

    社区规模有限,不推荐多搞 conf

  • 一个要把路由拆了的小轮子 at 2018年05月15日

    Dir["#{Rails.root}/config/routes/*.rb"].each { |f| require f }

  • 带 Namespace 的 Polymorphic 关联如何查询 at 2017年12月30日

    也遇到,处理代码:

    module Aaa
      module Bbb
        class ApplicationRecord < ActiveRecord::Base
          self.abstract_class = true
          self.store_full_sti_class = false
    
          def self.belongs_to(name, scope = nil, options = {})
            super(name, scope, options).tap do |hash|
              reflection = hash[name.to_s]
              def reflection.association_class
                if polymorphic?
                  BelongsToPolymorphicAssociation
                else
                  super
                end
              end unless store_full_sti_class
            end
          end
        end
    
        class BelongsToPolymorphicAssociation < ActiveRecord::Associations::BelongsToPolymorphicAssociation
          def klass
            type = owner[reflection.foreign_type]
            type.presence && Aaa::Bbb.const_get(type)
          end
        end
      end
    end
    
  • 调查一下论坛上用 Linux 的桌面环境 at 2017年09月05日

    啥时候能有个 linux 下的基本工具呀,一键加配置,测速什么的。console 就行呀

  • 调查一下论坛上用 Linux 的桌面环境 at 2017年06月29日
    • ubuntu server LTS 最新版(目前 16.04)
    • 无桌面环境
    • fvwm
    • 物理机器
  • 为什么感觉 Ruby 程序员生活质量普遍高? at 2017年04月03日

    好吧,我肯定是个假程序员。

  • Ruby 需要一个静态类型验证系统 at 2017年03月13日

    该出错的总要出错,type 能发现的也只能是其中一小部分。上类型如果对人的成本较大,还是要权衡。

  • 跳槽? at 2017年03月09日

    早期,纯因为薪资跳槽的占比可以设的更低一点。

  • [已关闭,结果公布] 送几个蛋人网的订阅账号 at 2017年03月08日

    呃,+1

  • 求推荐机械键盘 at 2017年03月07日

    已经晚了。 另,cherry 原厂。

  • Vim 下开发 Ruby on Rails 必装插件之 rails.vim 简单介绍 at 2017年02月20日

    一直在 linux 的 vim 上用,倒没有遇到卡的问题。 只遇到一个 scrooloose/syntastic 因为同步的原因,在同事的 mac vim 上面卡滞,在 linux vim 上也不卡。

  • 社区里还有多少人在用 Emacs 做 Ruby 开发? at 2017年02月08日

    vim +1

  • Rails 搭建微商城有哪些可以利用的模块,避免重复造轮子? at 2016年12月09日

    #5 楼 @yingce 我遇到过事务回滚,对象状态却变了,要 reload 一下才是原来的,回头我再仔细检查下吧。

  • 上一页
  • 1
  • 2
  • 3
  • 4
  • …
  • 27
  • 28
  • 下一页
关于 / RubyConf / Ruby 镜像 / RubyGems 镜像 / 活跃会员 / 组织 / API / 贡献者
由众多爱好者共同维护的 Ruby 中文社区,本站使用 Homeland 构建,并采用 Docker 部署。
服务器由 赞助 CDN 由 赞助
iOS 客户端 / Android 客户端 简体中文 / English