Skip to content

Instantly share code, notes, and snippets.

@Maroo-b
Maroo-b / gist:10a0417a0a9b9c8dfa25f0da9704f12b
Created November 1, 2024 06:12
Running Rubocop lint through Docker for VSCode
1. Add a script named rubocop to the local root project:
```
#!/bin/sh
docker-compose exec -T docker_service_name bundle exec rubocop -c .rubocop.yml "$@"
```
2. In VsCode settings add the following:
```
"[ruby]": {
"editor.defaultFormatter": "rubocop.vscode-rubocop"
@Maroo-b
Maroo-b / twilio_call_exporter.rb
Created August 23, 2018 08:12
Twilio call logs exporter
require "csv"
class TwilioCallExporter
DATE_FORMAT = "%Y-%m-%d %H:%M UTC"
attr_reader :to_phone_number, :start_date
def initialize(to_phone_number:, start_date:)
@to_phone_number = to_phone_number
@start_date = start_date
end