我有一个git的问题,更确切地说是gitignore.
我创建了一个空文件夹Initialized git
mkdir fold
cd fold
git init
Run Code Online (Sandbox Code Playgroud)
更新了gitignore(如下所示)
*.prjx
Run Code Online (Sandbox Code Playgroud)
致力于gitignore
git add .gitignore
git commit -m "update gitignore"
Run Code Online (Sandbox Code Playgroud)
现在我有几个文件(其中包括.prjx)和根目录中的文件夹(折叠),我想添加所有文件,但是当我运行时
git add *
Run Code Online (Sandbox Code Playgroud)
我收到以下信息
The following paths are ignored by one of your .gitignore files:
ftc.prjx
Use -f if you really want to add them.
fatal: no files added
Run Code Online (Sandbox Code Playgroud)
我不想添加它,我只想添加所有其他文件和文件夹.根据我的理解.gitignore应该正好处理,为什么我得到上面的消息?我错过了什么吗?
我正在努力配置Capistrano 3.1以部署托管在Github上的应用程序.
我正在关注Capistrano文档,我已成功完成第一步(从工作站到服务器的SSH密钥)和第二步(从我们的服务器到存储库主机)我能够成功运行ssh -A deploy@one-of-my-servers.com 'git ls-remote git@github.com:my_user/my_repo.git':
18f38afz261df35d462f7f4e2ca847d22f148a06 HEAD
18f38afz261df35d462f7f4e2ca847d22f148a06 refs/heads/master
Run Code Online (Sandbox Code Playgroud)
然而,ssh deploy@one-of-my-servers.com 'git ls-remote git@github.com:my_user/my_repo.git'失败了:
Permission denied (publickey).
Run Code Online (Sandbox Code Playgroud)
Capistrano医生建议
如果您收到错误"主机密钥验证失败".登录到您的服务器并以部署用户ssh git@github.com命令运行,将github.com添加到已知主机列表中.
所以,我试过但是我明白了
ssh git@github.com
Warning: Permanently added the RSA host key for IP address '192.30.252.131' to the list of known hosts.
Permission denied (publickey).
Run Code Online (Sandbox Code Playgroud)
我基本上无法成功访问Github仓库.
SSH文档说明:
Run Code Online (Sandbox Code Playgroud)-A Enables forwarding of the authentication agent connection. This can also be specified on a per-host basis in a configuration file.
如何在配置文件中基于每个主机指定?
我的本地机器运行Mac OSX Mavericks.VPS运行Ubuntu 12.04 …
我正在尝试从github更新我的webbynode,但我收到以下消息:
您要求从远程'git@github.com:sigbackup/gsapp.git'中提取,但未指定分支.因为这不是当前分支的默认配置远程,所以必须在命令行上指定分支.
所以我已经查看了这个论坛以寻求帮助,我发现了一些关于.git/config文件的评论,但我看起来已经很好了(至少对我来说):
[core]
repositoryformatversion = 0
filemode = true
bare = false
logallrefupdates = true
[remote "origin"]
fetch = +refs/heads/*:refs/remotes/origin/*
url = git@github.com:sigbackup/gsapp.git
[branch "master"]
remote = origin
merge = refs/heads/master
[branch "origin"]
remote = origin
merge = refs/heads/master
Run Code Online (Sandbox Code Playgroud)
我错过了什么吗?我有什么想法可以解决它吗?
PS我也试过git pull origin git@github.com:sigbackup/gsapp.git,我得到了
致命:找不到远程参考git@github.com
作为建议在这里,我已经取代chromedriver-helper与webdrivers上一个Rails 5.2的应用程序使用RSpec 3.8。
根据这篇文章,它应该是一个简单的替换,并在更新我Gemfile的规格工作之后。但是,我收到了一堆弃用警告
2019-04-23 13:33:02警告Selenium [DEPRECATION] Selenium :: WebDriver :: Error :: UnhandledError已弃用。请改用Selenium :: WebDriver :: Error :: UnknownError(确保驱动程序支持W3C WebDriver规范)。2019-04-23 13:33:02警告Selenium [DEPRECATION] Selenium :: WebDriver :: Error :: ElementNotVisibleError已弃用。请改用Selenium :: WebDriver :: Error :: ElementNotInteractableError(确保驱动程序支持W3C WebDriver规范)。2019-04-23 13:33:02警告Selenium [DEPRECATION] Selenium :: WebDriver :: Error :: InvalidElementStateError已过时。请改用Selenium :: WebDriver :: Error :: ElementNotInteractableError(确保驱动程序支持W3C WebDriver规范)。2019-04-23 13:33:02警告Selenium [DEPRECATION] Selenium :: WebDriver :: Error :: ElementNotSelectableError已弃用。使用硒::而是使用WebDriver :: Error :: ElementNotInteractableError(确保驱动程序支持W3C WebDriver规范)。2019-04-23 13:33:02警告Selenium [DEPRECATION] Selenium …
有没有办法在卡片内水平居中图像?
我有以下内容
<div class='column is-one-quarter has-text-centered'>
<div class='card equal-height'>
<div class='card-content'>
<figure class='image is-64x64'><img src='...'></figure>
</div>
</div>
</div>
Run Code Online (Sandbox Code Playgroud)
而我无法使图像居中.我试图is-centered将这两个添加到图和父div,但没有任何变化.
谢谢.
在 Alpine 3.10.1 上,我尝试使用headless_chrome.
config.before(:each, type: :system, js: true) do
driven_by :selenium, using: :headless_chrome
end
Run Code Online (Sandbox Code Playgroud)
我已经安装capybara和webdrivers.
由于我还没有找到Chrome在 Alpine上安装的方法,我尝试过Chromium(76.0.3809.87-r0)。但是,当我运行规范时,它找不到驱动程序。
ChildProcess::LaunchError: 没有那个文件或目录 - /root/.webdrivers/chromedriver
我也试过chromium-chromedriver直接通过 apk安装,但结果是一样的。
有没有安装方式Chrome上高山,或使用Chromium与Capybara?
我第一次尝试使用 TailwindCSS,我正在尝试自定义下面寺庙最后一行中的表格。
https://www.tailwindtoolbox.com/templates/admin-template-demo.php
我想在标题的右侧添加一个圆圈。就像是
我尝试了不同的解决方案,最接近我想要的解决方案是
<div class="border-b-2 rounded-tl-lg rounded-tr-lg p-2">
<h5 class="uppercase"><%= host.name %></h5>
<span class="rounded-full px-2 py-2 float-right"></span>
</div>
Run Code Online (Sandbox Code Playgroud)
这将绿点放在下边框上。显然float-right不是正确的方法,但我想不出办法让它发挥作用。
有任何想法吗?
我有一个Rails 5.0.4应用程序,我正在尝试获取js源映射
sprockets到4.0.0-beta5(最新)sprockets-rails到3.2.1(最新).app/assets/config/manifest.js如下
Run Code Online (Sandbox Code Playgroud)//= link application.js //= link application.css
但是,当我运行时bin/rails assets:precompile没有.map创建文件.
我在这里错过了什么吗?
我正在使用uglifier压缩机
config.assets.js_compressor = :uglifier
Run Code Online (Sandbox Code Playgroud)
UPDATE
经过几次研究,我更新了我的清单如下
Run Code Online (Sandbox Code Playgroud)//= link application.js //= link application.js.map //= link application.css
这会生成一个.map文件,但也会生成一堆之前未创建的文件.
I, Writing /appy/public/assets/application.js-2c9ef72a80f5f0c6011537311d91fd1196ae2bef80ed0b82b00c6eb87ee82af9.map
I, Writing /appy/public/assets/application.js-2c9ef72a80f5f0c6011537311d91fd1196ae2bef80ed0b82b00c6eb87ee82af9.map.gz
I, Writing /appy/public/assets/jquery.source-430f36f9b5f21aae8cc9dca6a81c4d3d84da5175eaedcf2fdc2c226302cb3575.js
I, Writing /appy/public/assets/jquery_ujs.source-784a997f6726036b1993eb2217c9cb558e1cbb801c6da88105588c56f13b466a.js
I, Writing /appy/public/assets/jquery-ui/core.source-62aad85719b507a830934d0fbe64de7816cd70c818eca1b06587484e94d65ec7.js
I, Writing /appy/public/assets/jquery-ui/widget.source-417dab6d8413c3e391f31430d6158e9e2211045c27756faad88479c980048ae3.js
I, Writing /appy/public/assets/jquery-ui/accordion.source-66807da00144fb00ff8ce5e181be52e74badb11213966ce258c89c000318340e.js
I, Writing /appy/public/assets/jquery-ui/position.source-ba98b4672be13a5780636b01c3daf137d14194857ca89cc8916ca8833534d54f.js
I, Writing /appy/public/assets/jquery-ui/menu.source-203fcd6601bca475f3af5e18f1456a2b6f73dfb73a0122c6782ce0b9eb530b21.js
I, Writing /appy/public/assets/jquery-ui/autocomplete.source-3989c376efd2db3eac613502e79e9728f1798ebe6b7972d4dc2b13949127cb37.js
I, Writing …Run Code Online (Sandbox Code Playgroud) 我曾经有以下
require 'factory_girl'
require_relative '../../support/factories/users.rb'
class UserMailerPreview < ActionMailer::Preview
def invitation
user = FactoryGirl.build(:user)
UserMailer.invitation(user)
end
end
Run Code Online (Sandbox Code Playgroud)
它正在使用FactoryGirl 4.8
现在,我已经更新到FactoryBot 4.8.2
require 'factory_bot'
require_relative '../../support/factories/users.rb'
class UserMailerPreview < ActionMailer::Preview
def invitation
user = FactoryBot.build(:user)
UserMailer.invitation(user)
end
end
Run Code Online (Sandbox Code Playgroud)
但是我明白了No such file to load -- factory_bot.rb。我需要什么?
谢谢您的帮助。
我正在使用布尔玛有一列卡片,无论内容如何,它们都需要具有相同的高度。为了实现这一点,我创建了以下课程
.equal-height
display: flex
flex-direction: column
height: 100%
Run Code Online (Sandbox Code Playgroud)
我的 HTML 看起来像
<div class='columns is-multiline'>
<div class='column is-one-fifth'>
<div class='card equal-height'>
<div class='card-content'>
# CONTENT GOES HERE
</div>
<div class='card-footer'>
# FOOTER GOES HERE
</div>
</div>
</div>
<div class='column is-one-fifth'>
<div class='card equal-height'>
<div class='card-content'>
# CONTENT GOES HERE
</div>
<div class='card-footer'>
# FOOTER GOES HERE
</div>
</div>
</div>
</div>
Run Code Online (Sandbox Code Playgroud)
这会产生类似的东西
现在我试图将card-footer粘在卡片的底部,如下所示。
我尝试过一些事情,flex但它们并没有真正意义。关于我如何做到这一点有什么想法吗?
bulma ×2
git ×2
github ×2
rspec ×2
alpine-linux ×1
capistrano3 ×1
css ×1
factory-bot ×1
flexbox ×1
sprockets ×1
ssh ×1
tailwind-css ×1