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
| url = "" # URL for large file | |
| # Use `copy_stream` and `foreach` to avoid loading the file into memory. | |
| filepath = Rails.root.join("tmp", "some-file.txt") | |
| IO.copy_stream(URI.parse(url).open, filepath) | |
| ids = [] | |
| File.foreach(filepath) { |id| ids << id&.strip&.to_i } # returns nil, does not display anything | |
| # If running this in IRB, avoid printing the result which is painfully slow | |
| # (the slowest portion by far) by running a second expression on that line. |
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 ruby:4.0.2-alpine AS base | |
| ENV BUNDLE_PATH="/usr/local/bundle" | |
| # Delete unnecessary files in default gems that cause security vulnerability false positives | |
| RUN find "/usr/local/lib/ruby/" -type f -iname "*Gemfile.lock" -delete | |
| # Post install, delete unnecessary files in gems that cause security vulnerability false positives | |
| RUN bundle config set without 'development test rubocop' && \ | |
| bundle install && \ |
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 | |
| # Include this script with no file extension in your project's `bin` directory. | |
| # Update the script with your organization slug. | |
| ORGANIZATION_SLUG = "" # Your Bugsnag organization slug | |
| require "io/console" # provides `STDIN.noecho` method | |
| begin |
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
| <?xml version="1.0" encoding="utf-8"?> | |
| <s:Application xmlns:fx="http://ns.adobe.com/mxml/2009" | |
| xmlns:s="library://ns.adobe.com/flex/spark" | |
| xmlns:mx="library://ns.adobe.com/flex/mx" | |
| minWidth="955" minHeight="600"> | |
| <s:layout> | |
| <s:HorizontalLayout gap="20" paddingTop="15" paddingLeft="15" /> | |
| </s:layout> |