Ecosyste.ms: OpenCollective

An open API service for software projects hosted on Open Collective.

github.com/shrinerb/shrine

File Attachment toolkit for Ruby applications
https://github.com/shrinerb/shrine

Finish DownloadError change for remote_url plugin

We want to allow users to convert custom HTTP exceptions into validation
errors in their downloa...

cf3b6fa7ed447799d79042a049f1f9516dcd380b authored over 5 years ago by Janko Marohnić <[email protected]>
Bring back Attacher#data_uri and Attacher#remote_url accessors

We removed them when we wanted to simplify everything, but they're
actually useful, as they help...

4101425b07c2703c9abd3b3815c48a7d45d0c315 authored over 5 years ago by Janko Marohnić <[email protected]>
Document validation plugin

4a6b976b11c6633ed388a69d920666f1f36f3a93 authored over 5 years ago by Janko Marohnić <[email protected]>
Document form_assign plugin

099cd4763608e7b26203ea48a1034d5dbc8085f7 authored over 5 years ago by Janko Marohnić <[email protected]>
Update backgrounding plugin docs with new API

44e7c172bf554f69be18daa6992dfc63f3d7d931 authored over 5 years ago by Janko Marohnić <[email protected]>
Use mirroring plugin in "Migrating File Storage" guide

fe032dbb28d3be814ae35a2a1752a024d512af87 authored over 5 years ago by Janko Marohnić <[email protected]>
Merge branch 'docs'

77ef3071048b9a992ca6faf67c514ae3c2fe41b9 authored over 5 years ago by Janko Marohnić <[email protected]>
Improve flexibility of mirroring plugin

This adds the API for calling the mirror upload/delete block:

file = Shrine.upload(io, :store...

e5570f535efae3f31aa80adc5496408396045a50 authored over 5 years ago by Janko Marohnić <[email protected]>
Remove attacher_options plugin

With the recent backgrounding change, it's not possible anymore to use
attacher_options plugin t...

342f8a5255d1f2ccc804e46145391c0f603be270 authored over 5 years ago by Janko Marohnić <[email protected]>
Move backgrounding outside of #promote and #destroy

Previously Attacher#promote and Attacher#destroy would be synchronous or
asynchronous depending ...

55885e43756721133c1e0ce9ba3d54c04ff1e1e4 authored over 5 years ago by Janko Marohnić <[email protected]>
Rename DeleteJob to DestroyJob in demo app

53bfe64f8d9c6b4f2d385a7f5a545b9ff73e62c9 authored over 5 years ago by Janko Marohnić <[email protected]>
Indicate that you can use JSON column in README

18165f06816d8460cd7ee6af19e4304d73cbdef3 authored over 5 years ago by Janko Marohnić <[email protected]>
Add missing link in entity plugin docs

3db50e0ab60321e968eb67f74145e88b801efcb6 authored over 5 years ago by Janko Marohnić <[email protected]>
Add Shrine.download_response to download_endpoint

This allows Rails uses who use an authentication framework that doesn't
support route-level auth...

9cb9e7e500ea7ce4bf31cc4f53d57ed7e549e95f authored over 5 years ago by Janko Marohnić <[email protected]>
Remove references to ActiveRecord::Base.raise_in_transactional_callbacks

In Active Record 6.0 this setting doesn't exist anymore, in 5.x it
defaults to true, and AFAIK i...

97bdb8199123c5dd92b21209ecdb6e677c1e3962 authored over 5 years ago by Janko Marohnić <[email protected]>
Change Google group links to Discourse

The discussion forum has moved from Google Groups to Discourse. The
reason is nicer UI and relia...

9b7c2fe4caacd9665ccd178075398dd9999d943f authored over 5 years ago by Janko Marohnić <[email protected]>
Improve the derivatives guide (#406)

* Improve the derivatives guide

* Update derivatives documentation based on feedback

* Cla...

a8792f317a91a1e6bc98b4ac58d98ff03065a26e authored over 5 years ago by Hiren Mistry <[email protected]>
Improve download_endpoint documentation with example (#410)

a61e44c518eccdd4669acddd9b00e44ba3a9e07b authored over 5 years ago by h0jeZvgoxFepBQ2C <[email protected]>
Fetch storage object lazily in Shrine instance

That makes testing easier, as well as playing on the console. It also
eliminates an additional i...

7b2399d00bd741741f787fda856f68d3a16c698c authored over 5 years ago by Janko Marohnić <[email protected]>
Bump to 3.0.0.beta2

51ad13ef8835e2f7bef5fd0709c1d03ca26903b9 authored over 5 years ago by Janko Marohnić <[email protected]>
Add changelog entries for previous changes

2075630f3f5e14449995b1c091c16f93c0d16301 authored over 5 years ago by Janko Marohnić <[email protected]>
Handle hashes in column plugin

In ROM we don't have a way to determine whether an entity attribute will
return a Hash or not. S...

1f67da86ba028c0464d80fd0a8c9bd4d9aec20be authored over 5 years ago by Janko Marohnić <[email protected]>
Use JsonSerializer class directly in column plugin

This simplifies Attacher's #inspect output, and our code as well.

c8624a9677f804569d7d3c02a5a33bff95ecf58e authored over 5 years ago by Janko Marohnić <[email protected]>
Fix handling JSON columns in activerecord plugin

The Shrine::Attacher rewrite broke support for JSON columns in
activerecord plugin. JSON column ...

bce45fddfc95852cf081403aaa0ce150d6db2089 authored over 5 years ago by Janko Marohnić <[email protected]>
Add mirroring plugin (#405)

The mirroring plugin adds the ability to replicate uploads and deletes
to other storages. This ...

ed2583b4f8be2698b6eaa9e234d9ed75900c6cd5 authored over 5 years ago by Janko Marohnić <[email protected]>
Fix test that's broken on MRI 2.3

56b627f651883cf7769192da19ba4d9a59baa744 authored over 5 years ago by Janko Marohnić <[email protected]>
Allow test failures on JRuby 9.2.8.0

JRuby has some obscure error on Travis that I don't have time to fix
right now, so we'll allow t...

28c0f174ee0961c6fe07ec19bbde7f7b1f6412ae authored over 5 years ago by Janko Marohnić <[email protected]>
Test on JRuby 9.2.8.0

3de94b705c0887195b2313e47ca60e26e638d9e5 authored over 5 years ago by Janko Marohnić <[email protected]>
Improve clarity (#404)

d568930cc2db24ca133cadb2e9d399ffbd003bc8 authored over 5 years ago by Hiren Mistry <[email protected]>
Emphasize that form fields are for the virtual attribute

Closes #401

1a771d3275af5333a625051567f72f85c69bc508 authored over 5 years ago by Janko Marohnić <[email protected]>
Tweaks to the demo app

* add back lost comments
* use fastimage for image extraction
* remove derivatives eversions com...

17d2dbdd7baf2f9a56449338dde698d3342fc4d8 authored over 5 years ago by Janko Marohnić <[email protected]>
A little editing (#403)

82283c91f3ead034b783cc9d00c7a2ff1d6df713 authored over 5 years ago by Hiren Mistry <[email protected]>
Allow disabling model attachment behaviour with `model: false`

The `type: :entity` approach isn't very clean, because it implies that
we have multiple types, w...

4b2ef4500e173b04fcb500668a9212fa9282c186 authored over 5 years ago by Janko Marohnić <[email protected]>
Improve activerecord/sequel/model/entity docs

We explain both Shrine::Attachment and Shrine::Attacher usage,
emphasizing that `#<name>_data` r...

033f336f65e3e5f69d763a64291d329ebcfc79ca authored over 5 years ago by Janko Marohnić <[email protected]>
Rename :callbacks sequel plugin option to :hooks

What Active Record calls "callbacks", Sequel calls "hooks". We want to
respect Sequel's terminol...

8243401302d202ce5072ce5448680d21872972c9 authored over 5 years ago by Janko Marohnić <[email protected]>
Tweak atomic helpers persistence tests

07fb7fa35039b0398a3c6bfce6f9a85169589e9e authored over 5 years ago by Janko Marohnić <[email protected]>
Auto-download UploadedFile in #process_derivatives

If the user wants to use an UploadedFile object as the source file for
processing derivatives, I...

e42dbac194adff61dfd76e4bfcfcebbb61f38eba authored over 5 years ago by Janko Marohnić <[email protected]>
Bump to 3.0.0.beta

da5dc99d775f02dc5621c969931888507b1e784b authored over 5 years ago by Janko Marohnić <[email protected]>
Add Attacher#file_data as lighter Attacher#data

When we're using backgrounding, we pass current attached file data to
the background job, so tha...

d7ab678dacb3418ee67f6495f8f934107c130dd1 authored over 5 years ago by Janko Marohnić <[email protected]>
Add .<name>_attacher method and Attacher#set_(entity|model)

The .<name>_attacher class method returns the Attacher instance without
the model/entity instanc...

22c0468e1e54906032be8cb138c4dc9ee58c1153 authored over 5 years ago by Janko Marohnić <[email protected]>
Move retrieving metadata attributes to Attacher class

ba2f38dcf0fec3f4cc4cf37ada8c102c8b9aabed authored over 5 years ago by Janko Marohnić <[email protected]>
Move retrieving derivatives settings to Attacher class

3807366ccf56aaf1b7c42337df1a2241e381f761 authored over 5 years ago by Janko Marohnić <[email protected]>
Send only :derivation in event payload

The :name and :args values in the payload were redundant, it's enough to
send only :derivation.
...

0c2f7f17d903efaf5b9ce4350e126319dfa02527 authored over 5 years ago by Janko Marohnić <[email protected]>
Start updating plugin docs

872417c87f70ea3e04067bdc0e6b8376a84a956d authored over 5 years ago by Janko Marohnić <[email protected]>
Improve default_storage plugin

Currently the dynamic storage block accepts record & name arguments. I
think this is limiting an...

ae31cad792e5cd781f194fc38af4888431d16af6 authored over 5 years ago by Janko Marohnić <[email protected]>
Demo app fixes

66b8082ee082d3ec0b79f05735de068208e85e48 authored over 5 years ago by Janko Marohnić <[email protected]>
Extract persistence docs to a single place

7a339322c4e8ddedf6805919f2264e691249f630 authored over 5 years ago by Janko Marohnić <[email protected]>
Simplify persistence interface

For each of the Attacher#persist, Attacher#atomic_persist and
Attacher#atomic_promote methods, w...

14f83be9b24f5bc4e3ed2c4129ce405bc3631eed authored over 5 years ago by Janko Marohnić <[email protected]>
Keep Shrine#_upload private in upload_options

7f194282bc6cc1e562a6a6f5c115b3b5d36aa8c9 authored over 5 years ago by Janko Marohnić <[email protected]>
Keep Shrine#basic_location private in infer_extension

4333b18ce37258163fd81e3a2d501285877050d2 authored over 5 years ago by Janko Marohnić <[email protected]>
Fix typo on README.md (#402)

4b2ae0c638f70e762fe698c139959db64f68cc86 authored over 5 years ago by Miral Achmed <[email protected]>
Add #<name>_changed? model method

When users are generating derivatives in their controller, this will be
the most common way:

...

5fa08d9d6b134e4ad19164f094976f59b899c33f authored over 5 years ago by Janko Marohnić <[email protected]>
Simplify ImageUploader in demo app

136ffbe26b2768adc8a00b38d7d467456f57c976 authored over 5 years ago by Janko Marohnić <[email protected]>
Remove Attacher#validate_options

The same can already be achieved with Attacher#assign_options from the
attacher_options plugin:
...

e11873a67fb4a0deb70d11c6d2933a1a85eefb84 authored over 5 years ago by Janko Marohnić <[email protected]>
Simplify defining entity/model methods in plugins

This removes some boilerplate around plugins defining methods only for
models. Now plugins can d...

b321d82d9ecc752ee815dd01d74e2a7f6b4f9593 authored over 5 years ago by Janko Marohnić <[email protected]>
Add #<name>_derivatives! wrapper around Attacher#create_derivatives

To generate derivatives in the controller, the user currently needs to
call Attacher#create_deri...

9a8177fb56078639c6f9a4d8e6daf678e5a807ec authored over 5 years ago by Janko Marohnić <[email protected]>
Change #create_derivatives to pass arguments to #process_derivatives

I think it will be much more common for people to want to pass arguments
to the processor than t...

1c3256c43395732ae8a8b17f2c3969a8de9e4e1c authored over 5 years ago by Janko Marohnić <[email protected]>
Extract generating metadata attributes into a method

6b43d81f36510864032aaac170ca3f8684bed0a5 authored over 5 years ago by Janko Marohnić <[email protected]>
Extract reverting change into a method in remove_invalid plugin

3fadfc23d9aed4ec39114f4aca54ece663d3cd34 authored over 5 years ago by Janko Marohnić <[email protected]>
Move default derivatives storage higher in the docs

The user will likely want to find out very soon if they can configure
derivatives to be uploaded...

be526c5f1437c7e2f32d36d9f000897daee4bfca authored over 5 years ago by Janko Marohnić <[email protected]>
Update migration guides

3be9960a68145175bb513152437483a141b0033d authored over 5 years ago by Janko Marohnić <[email protected]>
Update attacher guide

c145ddc6174aadc3358f7b19fae974db3d6ccb31 authored over 5 years ago by Janko Marohnić <[email protected]>
Bump to 3.0.0.alpha

c3fb5141902a2679058a9d42b28cb2274bb4a4e7 authored over 5 years ago by Janko Marohnić <[email protected]>
Show that #atomic_persist yields reloaded attacher

817edff96359bc7e1b591d274296340ad53fac66 authored over 5 years ago by Janko Marohnić <[email protected]>
Add form_assign plugin

This is useful when you want to assign attachment from form params but
don't want to create a fo...

dd5d465c0adbb601d72b6adcc6337ef7c16d3e46 authored over 5 years ago by Janko Marohnić <[email protected]>
Extract resolving file URL in upload_endpoint into a separate method

5c4bae3ceb8aae50e6502588269a145629630275 authored over 5 years ago by Janko Marohnić <[email protected]>
Few more tweaks to the derivatives docs

adde26844f06fc64a551ea2249987fd5fcded580 authored over 5 years ago by Janko Marohnić <[email protected]>
Fix typo in derivatives docs

d2dcc584ac5f174bbf6dc3f15fe8a12d2a0e2958 authored over 5 years ago by Janko Marohnić <[email protected]>
Make #create_derivatives top level, remove #store_derivatives

The method hierarchy is now as follows:

* Attacher#create_derivatives
* Attacher#process_deri...

fa3383a5713e8545342d9401bb84fd0932fb5265 authored over 5 years ago by Janko Marohnić <[email protected]>
Pass integer dimensions to #derivation_url

There is no need to use strings, it was just for remembering that they
will be integers in the d...

5115a4d162ae5cfc7a7908898d95a33138f1d86e authored over 5 years ago by Janko Marohnić <[email protected]>
Add :delete option to Shrine#upload

We're deleting uploaded files in multiple places (derivatives,
derivation_endpoint), so we add t...

98f1824cac59b8c1c5529116cd69845699df8670 authored over 5 years ago by Janko Marohnić <[email protected]>
Fix uploaded_file_test.rb

dbbdee5bef26e14fdf1b3f4c6fd5b0546b82e0b3 authored over 5 years ago by Janko Marohnić <[email protected]>
Eliminate #head_object request in S3#open

We want to return object's content length in S3#open, so that
UploadedFile#size can retrieve it ...

a36c5fe1e182c19307d1a003d9453fddbf477e70 authored over 5 years ago by Janko Marohnić <[email protected]>
Remove Storage#exists? check in download_endpoint

Now that Storage#open is required to raise Shrine::FileNotFound if file
is not found, we don't n...

b43f01a98b1ad56479f25f74d694f8100971c3d2 authored over 5 years ago by Janko Marohnić <[email protected]>
Remove extra Storage#exists? calls in derivation_endpoint

When :upload is set but no :upload_redirect, we're always first checking
whether the derivation ...

2ef3913e700286a20974308636253f79fc7325f5 authored over 5 years ago by Janko Marohnić <[email protected]>
Don't pass UploadedFile on download: false in derivation_endpoint

Now that derivation block is evaluated in context of a
Shrine::Derivation instance, the source U...

33a3c217c36b3b13185f1066d9944a7e5b399484 authored over 5 years ago by Janko Marohnić <[email protected]>
Remove :include_uploaded_file option in derivation_endpoint

It's not needed anymore now that derivation blocks are evaluated in
context of a Shrine::Derivat...

30f233adc4b01257bce64ed7fd1f2409a737d28f authored over 5 years ago by Janko Marohnić <[email protected]>
Evaluate derivation block in context of a Shrine::Derivation instance

It is not useful at all to evaluate it in context of an uploader
instance, because this doesn't ...

9c8c0de5b4e025fb7f0ad908b10cb69645e45a49 authored over 5 years ago by Janko Marohnić <[email protected]>
Remove :download_errors option in derivation_endpoint

Now that storages should raise Shrine::FileNotFound when file was not
found, we don't need the :...

87decb5a696f8ec2c4bd5eb7e6d596edbe7bfdf1 authored over 5 years ago by Janko Marohnić <[email protected]>
Raise Shrine::FileNotFound in Storage#open

In download_endpoint and derivation_endpoint it would be really useful
to know when Storage#open...

6fb4cfdff42bf5f94611149c1bd1ff15a6a92631 authored over 5 years ago by Janko Marohnić <[email protected]>
Make Attacher#map_derivative public

I've wanted to use it in migration scripts where I have access to the
attacher instance. It was ...

f9390c3c83874f4f97dc16eed27a9ec560af9777 authored over 5 years ago by Janko Marohnić <[email protected]>
Tweak upload.shrine and metadata.shrine event payload

I've wanted the :metadata information on the top level for the
upload.shrine event. In addition ...

019bc7abe06a1903ec9283ef2c418f871989bb8c authored over 5 years ago by Janko Marohnić <[email protected]>
Add ckeditor gem to the website

It recently added support for Shrine.

15c08631f36c454da530fbeef8f2359fb993aa11 authored over 5 years ago by Janko Marohnić <[email protected]>
Drop support for legacy download_endpoint URLs

Any /:storage/:id file URLs will now return a 404.

29e7310051e2354f1ce6879de96e532db2a4f454 authored over 5 years ago by Janko Marohnić <[email protected]>
Disable MIME type / Image Dimensions logging in demo app

e63b7c3b4f90406d0f7fb7a9b783ba8e31158902 authored over 5 years ago by Janko Marohnić <[email protected]>
Add Attacher#(store|create)_derivatives, deep merge derivatives

Instead of Attacher#add_derivatives and Attacher#upload_derivatives
optionally accepting a proce...

4b76a66a9cd1f288078b1ac813bb652004287b52 authored over 5 years ago by Janko Marohnić <[email protected]>
Update demo app with derivatives plugin

Because derivatives plugin requires explicit triggering of processing,
we don't need to use two ...

7e948f59aca73dbae5a7ce040654879755b036a0 authored over 5 years ago by Janko Marohnić <[email protected]>
Make :derivative option optional in docs

The :derivative option will only be available for derivative uploads,
otherwise that option won'...

e1eba49684948b9806394ad97c5b46a255e42597 authored over 5 years ago by Janko Marohnić <[email protected]>
Remove duplication in refresh_metadata plugin

e1db7c44586adc216a550fde2a8622995b8d2851 authored over 5 years ago by Janko Marohnić <[email protected]>
Integrate pretty_location plugin with derivatives

6c9d46c3df8a9347fa8eb356deb5fed72c532359 authored over 5 years ago by Janko Marohnić <[email protected]>
Fix Attacher.retrieve not working when called on Shrine::Attacher

When Shrine::Attachment module is used on a model/entity,
Attacher.retrieve would fail with Shri...

4898841bab91a85cbac26931a71ba8573f0c2702 authored over 5 years ago by Janko Marohnić <[email protected]>
Require same uploader class in UploadedFile#==

Currently UploadedFile#== allows the uploader class of the file on the
right hand side to be a s...

79f436d08850871b14dc92e862995b04ab75e765 authored over 5 years ago by Janko Marohnić <[email protected]>
Move remove_invalid plugin to "Validation" section

cc0b0e8be398de1fc00b8f37af83f35926a77429 authored over 5 years ago by Janko Marohnić <[email protected]>
Improve merging and removing derivatives

We add the missing Attacher#merge_derivatives layer between
Attacher#add_derivatives and Attache...

fee27a8102713ca18a1a8c8d2796007787518f21 authored over 5 years ago by Janko Marohnić <[email protected]>
Test that derivatives are closed before deletion

9f6a91b3304a858150f5c4eb53d360e4259b7f46 authored over 5 years ago by Janko Marohnić <[email protected]>
Inline Attacher#process_derivatives

0518b23302291f10791214c9a72a29cde9132a13 authored over 5 years ago by Janko Marohnić <[email protected]>
Add :close option for disabling closing file after upload

There could be use cases where the user still wants to use the raw
file after it has been upload...

2f3207945368989ebdf8aefe2b45605b841b79ee authored over 5 years ago by Janko Marohnić <[email protected]>
Link model/entity documentation from source code

ea2df8d0b32effb19610f16b7306d0096fa2b928 authored over 5 years ago by Janko Marohnić <[email protected]>
Improve test coverage

This doesn't get us to 100% yet, but the rest is not so important.

ee405cbaac368778b55f80f8c7884465ef578fef authored over 5 years ago by Janko Marohnić <[email protected]>
Move storage tests to test/storage/*

4f7850e69652d4c08cdbc5ed654861bd04dbc902 authored over 5 years ago by Janko Marohnić <[email protected]>