-
Open Device Manager:
- Right-click the Windows Start icon.
- Select Device Manager from the menu.
(If you’re not in administrator mode, right-click and choose Run as administrator.)
-
Expand the Device Lists:
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
stats = Sidekiq::Stats.new | |
stats.queues | |
stats.enqueued | |
stats.processed | |
stats.failed |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
# deps and their versions in gemspec | |
cat name.gemspec | ag -o '(?<=dependency).*(?<=[<>=]\s)(?>\d+\.?\d+)' | tr -d "',><=~" | |
# deps and their version on RubyGems | |
cat british.gemspec | ag -o '(?<=dependency).*(?<=[<>=]\s)(?>\d+\.?\d+)' | tr -d "',><=~" | awk '{ print $1 }' | xargs gem info -r | ag '\(\d+\.\d+\.\d+\)' | |
# gemspec and current remote versions side-by-side | |
paste <(cat $(ls | ag gemspec) | ag -o '(?<=dependency).*(?<=[<>=]\s)(?>\d+\.?\d+)' | tr -d "',><=~") <(cat $(ls | ag gemspec) | ag -o '(?<=dependency).*(?<=[<>=]\s)(?>\d+\.?\d+)' | tr -d "',><=~" | awk '{ print $1 }' | xargs gem info -r | ag -o '(?<=\()(\d+\.\d+\.\d+)(?!>\))') |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
# From http://garmoncheg.blogspot.com/2012/06/pretty-git-log.html | |
git config --global alias.lg "log --color --graph --pretty=format:'%Cred%h%Creset -%C(yellow)%d%Creset %s %Cgreen(%cr) %C(bold blue)<%an>%Creset' --abbrev-commit --" |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#!/usr/bin/env ruby | |
# frozen_string_literal: true | |
require "socket" | |
class Connection | |
def initialize(client:, server:) | |
@client = client | |
@server = server | |
end |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
namespace :db do | |
desc "Outputs any invalid data records" | |
task :invalid_records => :environment do | |
puts "\n** Testing record validating in #{Rails.env.capitalize} environment**\n" | |
ActiveRecord::Base.send(:subclasses).each do |model| | |
puts "#{model} records (#{model.count})" | |
next if model.count == 0 | |
invalid = model.all.reject(&:valid?) | |
if invalid.size.zero? |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
# frozen_string_literal: true | |
# | |
# Uncomment this and change the path if necessary to include your own | |
# components. | |
# See https://github.com/heartcombo/simple_form#custom-components to know | |
# more about custom components. | |
# Dir[Rails.root.join('lib/components/**/*.rb')].each { |f| require f } | |
# | |
# Use this setup block to configure all options available in SimpleForm. | |
SimpleForm.setup do |config| |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
``` | |
** Invoke db:environment:set (first_time) | |
** Invoke db:load_config (first_time) | |
** Invoke environment (first_time) | |
** Execute environment | |
** Execute db:load_config | |
** Execute db:environment:set | |
** Invoke db:schema:load (first_time) | |
** Invoke db:load_config | |
** Invoke db:check_protected_environments (first_time) |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
== Command ["bin/rails db:prepare"] failed == | |
➜ railsdevs.com git:(main) ✗ git status | |
On branch main | |
Your branch is up to date with 'origin/main'. | |
Changes not staged for commit: | |
(use "git add <file>..." to update what will be committed) | |
(use "git restore <file>..." to discard changes in working directory) | |
modified: db/migrate/20211028230858_create_active_storage_tables.active_storage.rb | |
modified: db/migrate/20211128095707_create_businesses.rb |
NewerOlder