Skip to content

Instantly share code, notes, and snippets.

View YumaInaura's full-sized avatar

いなうらゆうま ( 稲浦悠馬 ) YumaInaura

View GitHub Profile
@YumaInaura
YumaInaura / GIST.md
Created September 4, 2024 00:57
Unable to upload hidden file , directory ( actions/upload-artifact@v4 )

Trouble

Error

Error: No files were found with the provided path: .up/. No artifacts will be uploaded.

Resolve

@YumaInaura
YumaInaura / README.md
Last active August 8, 2024 00:02
Github Actions API - Post or Update Secret Key to Repository

Get Repository Public Key

curl -L \
  -H "Accept: application/vnd.github+json" \
  -H "Authorization: Bearer <YOUR-TOKEN>" \
  -H "X-GitHub-Api-Version: 2022-11-28" \
  https://api.github.com/repos/OWNER/REPO/actions/secrets/public-key
@YumaInaura
YumaInaura / README.md
Created June 8, 2024 04:05
Rails + Enumerize Troulble – ActiveRecord Instance returns nil But Datable data value is exists

Trouble

Example Class

class Example < ApplicationRecord
  extend Enumerize

  enumerize :name, in: %i[alice bob carol]
end
@YumaInaura
YumaInaura / README.md
Created June 6, 2024 23:13
Rails - Check before delete column migration, column value exist or not

Example

def up
  if Example.where.not(foo_column: nil).exists?
    raise 'Example.foo_column has some value'
  end

  remove_column  :examples, :foo_column
end
@YumaInaura
YumaInaura / README.md
Created June 2, 2024 22:16
Playwright - Expect message of window.comfirm Example

Expect message and comfirm dialog

Good

  page.on('dialog', async (dialog) => {
    expect(dialog.message()).toContain('Expected Message')
    await dialog.accept()
  })
@YumaInaura
YumaInaura / README.md
Created May 31, 2024 02:16
Thoughts on new development tools/CI – Cursor / Copilot / Code Rabbit / Renovate / CleanShotX etc.

Development environment tools

Good

  • Copilot++, a VSCode-based editor (Cursor) -> It's very useful, I can't do without it anymore
  • CleanShot X (Mac app that lets you take screenshots and draw) -> Useful

usually

@YumaInaura
YumaInaura / README.md
Created May 27, 2024 21:45
I'm wondering whether to switch back to iTerm2 from WARP for the Mac console.

Disadvantages of WARP

  • You cannot set your favorite shortcuts.
  • Searching from the command history cannot be performed as a wildcard, but as a prefix match.
  • Command history may not be shared across multiple tabs
  • Japanese input in Vim is not good enough
  • SSH connection to the server immediately disconnects

Advantages of WARP

@YumaInaura
YumaInaura / README.md
Created May 23, 2024 22:25
Rails - Example of how to run Rspec on Docker from Makefile

overview

  • Requires docker-compose configuration
  • Specify the file name using RSPEC_TARGET as an argument to Make
  • local assumes that the Rails directory is below the directory where the Makefile is located (e.g. some_rails_directory )

Makefile

rspec:
@YumaInaura
YumaInaura / PLAYWRIGHT.md
Last active February 22, 2024 17:21
Playwright – select file and send formData
@YumaInaura
YumaInaura / TLANSLATE.md
Created January 27, 2019 11:43
How to check the number of remaining tasks and number of zaps in Zapier