Skip to content

Commit

Permalink
Merge pull request #4 from adrian-gheorghe/develop
Browse files Browse the repository at this point in the history
Add Readme Demo Images. Change JPG quality to 84
  • Loading branch information
adrian-gheorghe authored Jul 14, 2019
2 parents ee96cbb + aa37b7f commit ad7fa85
Show file tree
Hide file tree
Showing 5 changed files with 11 additions and 2 deletions.
11 changes: 10 additions & 1 deletion README.md
Original file line number Diff line number Diff line change
Expand Up @@ -42,6 +42,7 @@ sh -c "$(curl -fsSL https://raw.githubusercontent.com/adrian-gheorghe/mediafaker
Download latest from the releases page: https://github.com/adrian-gheorghe/mediafaker/releases.
# Usage
mediafaker can be used in 2 ways, to either fake a local path or a remote url / ssh path.
## Local
Expand All @@ -52,6 +53,7 @@ mediafaker local \
--source="/opt/media" \
--destination="/home/project/public/fake/destination"
```
## Remote
When the source and destination paths are on different hosts mediafaker uses https://github.com/adrian-gheorghe/moni in order to generate a json representation of the directory you want to fake.
Expand Down Expand Up @@ -167,7 +169,14 @@ mediafaker ssh \
## Image Pixelation
One of the main features of mediafaker is that it will read image files and create a pixelated version of the original image keeping the same dimensions and main colors. This saves time and precious disk space while also allowing you to have a drop in replacement for your images
filefaker will proceed to create an exact replica of the source directory, by creating mock files. The mock files created try to follow the originals as much as possible.
mediafaker will proceed to create an exact replica of the source directory, by creating mock files. The mock files created try to follow the originals as much as possible.
#### Magento Luma Sample Data 1
![MediaFaker 1](demo/mediafaker2.jpg)
#### Magento Luma Sample Data 2
![MediaFaker 1](demo/mediafaker3.jpg)
#### Magento Luma Original
![MediaFaker 1](demo/mediafaker1.jpg)
## Documents
- Xlsx support added using the https://github.com/tealeg/xlsx package
Expand Down
Binary file added demo/mediafaker1.jpg
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file added demo/mediafaker2.jpg
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file added demo/mediafaker3.jpg
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
2 changes: 1 addition & 1 deletion fakers/jpg.go
Original file line number Diff line number Diff line change
Expand Up @@ -103,7 +103,7 @@ func (faker *Jpg) FakeTreeFile(item extpoints.TreeFile, destinationPath string)
return err
}

err = jpeg.Encode(destinationImage, outImg, &jpeg.Options{Quality: 65})
err = jpeg.Encode(destinationImage, outImg, &jpeg.Options{Quality: 84})
if err != nil {
return err
}
Expand Down

0 comments on commit ad7fa85

Please sign in to comment.