<?xml version="1.0" encoding="UTF-8"?>
<rss version="2.0" xmlns:atom="http://www.w3.org/2005/Atom" xmlns:dc="http://purl.org/dc/elements/1.1/">
  <channel>
    <title>DEV Community: Chokri K'</title>
    <description>The latest articles on DEV Community by Chokri K' (@chokri).</description>
    <link>https://dev.to/chokri</link>
    <image>
      <url>https://media2.dev.to/dynamic/image/width=90,height=90,fit=cover,gravity=auto,format=auto/https:%2F%2Fdev-to-uploads.s3.amazonaws.com%2Fuploads%2Fuser%2Fprofile_image%2F119257%2F51787b48-9118-4a11-ad17-711102dcaba0.jpg</url>
      <title>DEV Community: Chokri K'</title>
      <link>https://dev.to/chokri</link>
    </image>
    <atom:link rel="self" type="application/rss+xml" href="https://dev.to/feed/chokri"/>
    <language>en</language>
    <item>
      <title>[Ubuntu] Ubuntu 20.04 ‘Focal Fossa’ will be there</title>
      <dc:creator>Chokri K'</dc:creator>
      <pubDate>Wed, 25 Mar 2020 13:22:56 +0000</pubDate>
      <link>https://dev.to/chokri/ubuntu-ubuntu-20-04-focal-fossa-will-be-there-731</link>
      <guid>https://dev.to/chokri/ubuntu-ubuntu-20-04-focal-fossa-will-be-there-731</guid>
      <description>&lt;p&gt;This is a special year full of events, certainly, with the CODIV-19 disease epidemic. The Ubuntu community still wondering the new Ubuntu LTS release baptized “Focal Fossa”.&lt;/p&gt;

&lt;p&gt;&lt;a href="https://res.cloudinary.com/practicaldev/image/fetch/s--MbFfN_Oe--/c_limit%2Cf_auto%2Cfl_progressive%2Cq_auto%2Cw_800/https://i2.wp.com/khalifa.tn/wp-content/uploads/2020/03/fossa.jpg%3Ffit%3D700%252C400%26ssl%3D1%3Fv%3D1585142570" class="article-body-image-wrapper"&gt;&lt;img src="https://res.cloudinary.com/practicaldev/image/fetch/s--MbFfN_Oe--/c_limit%2Cf_auto%2Cfl_progressive%2Cq_auto%2Cw_800/https://i2.wp.com/khalifa.tn/wp-content/uploads/2020/03/fossa.jpg%3Ffit%3D700%252C400%26ssl%3D1%3Fv%3D1585142570" alt="" width="700" height="400"&gt;&lt;/a&gt;&lt;/p&gt;

&lt;p&gt;The 20.04 release is the successor of 18.04 release that will end in the year of 2023. Every LTS release is  &lt;strong&gt;supported for 5 years&lt;/strong&gt;.&lt;/p&gt;

&lt;p&gt;The official release date will be April, 23, 2020. The Milestones throughout the &lt;em&gt;Focal Fossa&lt;/em&gt; development cycle include:&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;
&lt;strong&gt;Testing week&lt;/strong&gt; : January 9, 2020&lt;/li&gt;
&lt;li&gt;
&lt;strong&gt;UI Freeze&lt;/strong&gt; : March 19, 2020&lt;/li&gt;
&lt;li&gt;
&lt;strong&gt;Ubuntu 20.04&lt;/strong&gt;   &lt;strong&gt;Beta:&lt;/strong&gt;  April 2, 2020&lt;/li&gt;
&lt;li&gt;
&lt;strong&gt;Kernel Freeze&lt;/strong&gt; : April 9, 2020&lt;/li&gt;
&lt;li&gt;
&lt;strong&gt;Release Candidate:&lt;/strong&gt;  April 16, 2020&lt;/li&gt;
&lt;/ul&gt;

&lt;p&gt;This is the list of new features and changes that will be scheduled to land in this newest release of Ubuntu:&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;New Theme “Yaru Theme”&lt;/li&gt;
&lt;li&gt;&lt;strong&gt;&lt;a href="https://www.omgubuntu.co.uk/2020/02/gnome-3-36-features"&gt;GNOME 3.36&lt;/a&gt;&lt;/strong&gt;&lt;/li&gt;
&lt;li&gt;&lt;strong&gt;&lt;a href="https://www.omgubuntu.co.uk/2019/11/linux-5-4-kernel-release-features"&gt;Linux Kernel 5.4&lt;/a&gt;&lt;/strong&gt;&lt;/li&gt;
&lt;li&gt;&lt;strong&gt;Improved ZFS install support&lt;/strong&gt;&lt;/li&gt;
&lt;li&gt;&lt;strong&gt;New wallpaper&lt;/strong&gt;&lt;/li&gt;
&lt;li&gt;&lt;strong&gt;Smaller .iso image&lt;/strong&gt;&lt;/li&gt;
&lt;li&gt;&lt;strong&gt;Lightning extension added to Thunderbird&lt;/strong&gt;&lt;/li&gt;
&lt;li&gt;&lt;strong&gt;Multi-monitor support in GDM&lt;/strong&gt;&lt;/li&gt;
&lt;li&gt;&lt;strong&gt;Gaming-related improvements&lt;/strong&gt;&lt;/li&gt;
&lt;li&gt;&lt;strong&gt;&lt;a href="https://www.omgubuntu.co.uk/2019/10/ubuntu-improves-gnome-shell-performance"&gt;Better GNOME Shell performance&lt;/a&gt;&lt;/strong&gt;&lt;/li&gt;
&lt;/ul&gt;

&lt;p&gt;&lt;a href="https://res.cloudinary.com/practicaldev/image/fetch/s--vuAXKro6--/c_limit%2Cf_auto%2Cfl_progressive%2Cq_auto%2Cw_800/https://i1.wp.com/khalifa.tn/wp-content/uploads/2020/03/light-grey-orange-exploration.jpg%3Ffit%3D700%252C394%26ssl%3D1%3Fv%3D1585142602" class="article-body-image-wrapper"&gt;&lt;img src="https://res.cloudinary.com/practicaldev/image/fetch/s--vuAXKro6--/c_limit%2Cf_auto%2Cfl_progressive%2Cq_auto%2Cw_800/https://i1.wp.com/khalifa.tn/wp-content/uploads/2020/03/light-grey-orange-exploration.jpg%3Ffit%3D700%252C394%26ssl%3D1%3Fv%3D1585142602" alt="" width="700" height="394"&gt;&lt;/a&gt;&lt;/p&gt;

&lt;p&gt;&lt;em&gt;Source: &lt;a href="https://www.omgubuntu.co.uk/2019/10/ubuntu-20-04-release-featuresomgubuntu"&gt;omgubuntu&lt;/a&gt;&lt;/em&gt;&lt;/p&gt;

&lt;p&gt;The post &lt;a href="https://khalifa.tn/ubuntu-ubuntu-20-04-focal-fossa-will-be-there/"&gt;[Ubuntu] Ubuntu 20.04 ‘Focal Fossa’ will be there&lt;/a&gt; appeared first on &lt;a href="https://khalifa.tn"&gt;C.Khalifa&lt;/a&gt;.&lt;/p&gt;

</description>
      <category>linux</category>
      <category>ubuntu</category>
    </item>
    <item>
      <title>CakePHP 4.0 🍓 Strawberry is out, a new Chapter for PHP dev</title>
      <dc:creator>Chokri K'</dc:creator>
      <pubDate>Tue, 17 Dec 2019 10:47:56 +0000</pubDate>
      <link>https://dev.to/chokri/cakephp-4-0-strawberry-is-out-a-new-chapter-for-php-dev-2i69</link>
      <guid>https://dev.to/chokri/cakephp-4-0-strawberry-is-out-a-new-chapter-for-php-dev-2i69</guid>
      <description>&lt;h2&gt;
  
  
  What is CakePHP?
&lt;/h2&gt;

&lt;p&gt;CakePHP is a free, open-source, rapid development framework for PHP. It’s a foundational structure for programmers to create web applications. Since it’s based on MVC architecture, that makes it structured, rapid and more flexible.&lt;/p&gt;

&lt;p&gt;Today, the CakePHP team released the new version : Alpha &lt;a href="https://dev.to/chokri/what-s-new-with-cakephp-4-2fjf-temp-slug-5613412"&gt;version in April&lt;/a&gt;. A new chapter for CakePHP with a stable API. CakePHP 3.x moves into maintenance mode while 2.x moves into security release mode.&lt;/p&gt;

&lt;h2&gt;
  
  
  How to upgrade 3.x website?
&lt;/h2&gt;

&lt;p&gt;CakePHP 4.0 contains a lot of breaking changes and it’s not compatible with 3.x releases. If you attempt to migrate your website you have to follow this &lt;a href="https://book.cakephp.org/4/en/appendices/4-0-migration-guide.html"&gt;migration guide.&lt;/a&gt; It’s covering all the deprecated, removed, and new features.&lt;/p&gt;

&lt;p&gt;Additionally, CakePHP team offers an &lt;a href="https://book.cakephp.org/4/en/appendices/4-0-upgrade-guide.html"&gt;upgrade guide&lt;/a&gt; which gives a step-by-step guide and CLI tool to help us upgrade our application. To help improve these documents we have to help them collect more feedback from up while upgrading by opening issues in the &lt;a href="https://github.com/cakephp/cakephp/issues"&gt;official repository&lt;/a&gt;&lt;/p&gt;

&lt;h2&gt;
  
  
  Key Features
&lt;/h2&gt;

&lt;ul&gt;
&lt;li&gt;PHP 7.2 required.&lt;/li&gt;
&lt;li&gt;Streamlined APIs with all deprecated methods and behavior removed.&lt;/li&gt;
&lt;li&gt;Additional typehints across the framework giving you errors faster.&lt;/li&gt;
&lt;li&gt;Improved error messages across the framework.&lt;/li&gt;
&lt;li&gt;A refreshed application skeleton design.&lt;/li&gt;
&lt;li&gt;New database types for fixed length strings (CHAR), datetime with microseconds, and datetime with timezone types.&lt;/li&gt;
&lt;li&gt;Table now features OrFail methods that raise exceptions on failure making error handling more explicit and straightforward.&lt;/li&gt;
&lt;li&gt;Middleware for CSP headers, Form tampering prevention, and HTTPS enforcement.&lt;/li&gt;
&lt;li&gt;Cake\Routing\Asset to make generating asset URLs simple from anywhere in your application code.&lt;/li&gt;
&lt;li&gt;FormHelper now generates HTML5 validation errors.&lt;/li&gt;
&lt;li&gt;FormHelper now generates HTML5 datetime input elements.&lt;/li&gt;
&lt;/ul&gt;

&lt;p&gt;Source: &lt;a href="https://bakery.cakephp.org/2019/12/15/cakephp_400_released.html"&gt;https://bakery.cakephp.org/2019/12/15/cakephp_400_released.html&lt;/a&gt;&lt;/p&gt;

&lt;p&gt;The post &lt;a href="https://khalifa.tn/cakephp-4-0-strawberry-is-out-a-new-chapter-for-php-dev/"&gt;CakePHP 4.0 🍓 Strawberry is out, a new Chapter for PHP dev&lt;/a&gt; appeared first on &lt;a href="https://khalifa.tn"&gt;C.Khalifa&lt;/a&gt;.&lt;/p&gt;

</description>
      <category>technology</category>
      <category>cakephp</category>
    </item>
    <item>
      <title>Why is React so popular?</title>
      <dc:creator>Chokri K'</dc:creator>
      <pubDate>Fri, 06 Dec 2019 14:55:31 +0000</pubDate>
      <link>https://dev.to/chokri/why-is-react-so-popular-54mp</link>
      <guid>https://dev.to/chokri/why-is-react-so-popular-54mp</guid>
      <description>&lt;p&gt;This is not a comparison between Vue, angular and React. This post is according to Indeed.com with over than 60,000 job offers. I’ll talk about why React is the most popular JavaScript library.&lt;/p&gt;

&lt;p&gt;&lt;a href="https://res.cloudinary.com/practicaldev/image/fetch/s--J_Ns-OXP--/c_limit%2Cf_auto%2Cfl_progressive%2Cq_auto%2Cw_800/https://i2.wp.com/miro.medium.com/max/1200/1%2AfLvLBaoQ4FIt7xf5bY8CBg.png%3Fresize%3D443%252C274%26ssl%3D1" class="article-body-image-wrapper"&gt;&lt;img src="https://res.cloudinary.com/practicaldev/image/fetch/s--J_Ns-OXP--/c_limit%2Cf_auto%2Cfl_progressive%2Cq_auto%2Cw_800/https://i2.wp.com/miro.medium.com/max/1200/1%2AfLvLBaoQ4FIt7xf5bY8CBg.png%3Fresize%3D443%252C274%26ssl%3D1" alt="" width="443" height="274"&gt;&lt;/a&gt;&lt;/p&gt;

&lt;p&gt;All JavaScript developers know how hard is working with DOM API. React make it easy to use them, especially when we talk about Event Listeners. It suggests to take more control and power over when something happens in the virtual DOM when mounting, updating and unmounting components.&lt;/p&gt;

&lt;p&gt;This library helps describe the User Interface, each element is a component. It’s a design philosophy with virtual DOM and batched DOM updates makes it really fast and easy to test each component.&lt;/p&gt;

&lt;p&gt;With React life cycle, no component will be mounted before each child component of it gets mounted first. And this adds more robustness and more security to an app. For example, We can secure the whole application and have nothing mounted if the user is not logged in.&lt;/p&gt;

&lt;p&gt;It’s very hard to write HTML into JavaScript. Personally , I used mustache JS for templates. I remember how it’s complicated to append HTML into DOM. React made JSX very easy to use.&lt;/p&gt;

&lt;p&gt;React was hard to understand with complicated standards, Design patterns and its APIs like createRef, createClass and createElement…, etc. It’s harder when developers have to make a huge form with many functions to bind them into the class component. When the React team had announced functional components and hooks, React become easier to understand and very easy to use than before.&lt;/p&gt;

&lt;p&gt;For me, as a Lead Front developer in a recent mission, there is no substantial difference in which framework to choose. Vue.js is also on board, every framework has its own pros and cons&lt;/p&gt;

&lt;p&gt;&lt;a href="https://res.cloudinary.com/practicaldev/image/fetch/s--lNFPxHjx--/c_limit%2Cf_auto%2Cfl_progressive%2Cq_66%2Cw_800/https://i1.wp.com/media.giphy.com/media/YVPwi7L2izTJS/giphy.gif%3Fresize%3D300%252C167%26ssl%3D1" class="article-body-image-wrapper"&gt;&lt;img src="https://res.cloudinary.com/practicaldev/image/fetch/s--lNFPxHjx--/c_limit%2Cf_auto%2Cfl_progressive%2Cq_66%2Cw_800/https://i1.wp.com/media.giphy.com/media/YVPwi7L2izTJS/giphy.gif%3Fresize%3D300%252C167%26ssl%3D1" alt="Confused Trailer Park Boys GIF" width="300" height="167"&gt;&lt;/a&gt;&lt;/p&gt;

&lt;p&gt;Leave a comment if you do not agree &lt;a href="https://res.cloudinary.com/practicaldev/image/fetch/s--Q-Gs9eEo--/c_limit%2Cf_auto%2Cfl_progressive%2Cq_auto%2Cw_800/https://s.w.org/images/core/emoji/12.0.0-1/72x72/1f612.png" class="article-body-image-wrapper"&gt;&lt;img src="https://res.cloudinary.com/practicaldev/image/fetch/s--Q-Gs9eEo--/c_limit%2Cf_auto%2Cfl_progressive%2Cq_auto%2Cw_800/https://s.w.org/images/core/emoji/12.0.0-1/72x72/1f612.png" alt="😒" width="72" height="72"&gt;&lt;/a&gt;&lt;/p&gt;

&lt;p&gt;The post &lt;a href="https://dev.to/chokri/why-react-is-so-popular-35bc"&gt;Why is React so popular?&lt;/a&gt; appeared first on &lt;a href="https://khalifa.tn"&gt;C.Khalifa&lt;/a&gt;.&lt;/p&gt;

</description>
      <category>technology</category>
      <category>react</category>
    </item>
    <item>
      <title>Why React is so popular?</title>
      <dc:creator>Chokri K'</dc:creator>
      <pubDate>Fri, 06 Dec 2019 14:55:31 +0000</pubDate>
      <link>https://dev.to/chokri/why-react-is-so-popular-35bc</link>
      <guid>https://dev.to/chokri/why-react-is-so-popular-35bc</guid>
      <description>&lt;p&gt;This is not a comparing between Vue, angular and React. This post is according to Indeed.com with over than 60,000 job offers. I’ll talk about why React is the most popular JavaScript library.&lt;/p&gt;

&lt;p&gt;&lt;a href="https://res.cloudinary.com/practicaldev/image/fetch/s--J_Ns-OXP--/c_limit%2Cf_auto%2Cfl_progressive%2Cq_auto%2Cw_800/https://i2.wp.com/miro.medium.com/max/1200/1%2AfLvLBaoQ4FIt7xf5bY8CBg.png%3Fresize%3D443%252C274%26ssl%3D1" class="article-body-image-wrapper"&gt;&lt;img src="https://res.cloudinary.com/practicaldev/image/fetch/s--J_Ns-OXP--/c_limit%2Cf_auto%2Cfl_progressive%2Cq_auto%2Cw_800/https://i2.wp.com/miro.medium.com/max/1200/1%2AfLvLBaoQ4FIt7xf5bY8CBg.png%3Fresize%3D443%252C274%26ssl%3D1" alt="" width="443" height="274"&gt;&lt;/a&gt;&lt;/p&gt;

&lt;p&gt;All JavaScript developers know how hard is working with DOM API. React make it easy to use them, especially when we talk about Event Listeners. It suggests to take more control and power over when something happens in the virtual DOM when mounting, updating and unmounting components.&lt;/p&gt;

&lt;p&gt;This library helps describe the User Interface, each element is a component. It’s a design philosophy with virtual DOM and batched DOM updates makes it really fast and easy to test each component.&lt;/p&gt;

&lt;p&gt;With React life cycle, no component will be mounted before each child component of it gets mounted first. And this adds more robustness and more security to an app. For example, We can secure the whole application and have nothing mounted if the user is not logged in.&lt;/p&gt;

&lt;p&gt;It’s very hard to write HTML into JavaScript. Personally , I used mustache JS for templates. I remember how it’s complicated to append HTML into DOM. React made JSX very easy to use.&lt;/p&gt;

&lt;p&gt;React was hard to understand with complicated standards, Design patterns and its APIs like createRef, createClass and createElement…, etc. It’s harder when developers have to make a huge form with many functions to bind them into the class component. When the React team had announced functional components and hooks, React become easier to understand and very easy to use than before.&lt;/p&gt;

&lt;p&gt;For me, as a Lead Front developer in a recent mission, there is no substantial difference in which framework to choose. Vue.js is also on board, every framework has its own pros and cons&lt;/p&gt;

&lt;p&gt;&lt;a href="https://res.cloudinary.com/practicaldev/image/fetch/s--lNFPxHjx--/c_limit%2Cf_auto%2Cfl_progressive%2Cq_66%2Cw_800/https://i1.wp.com/media.giphy.com/media/YVPwi7L2izTJS/giphy.gif%3Fresize%3D300%252C167%26ssl%3D1" class="article-body-image-wrapper"&gt;&lt;img src="https://res.cloudinary.com/practicaldev/image/fetch/s--lNFPxHjx--/c_limit%2Cf_auto%2Cfl_progressive%2Cq_66%2Cw_800/https://i1.wp.com/media.giphy.com/media/YVPwi7L2izTJS/giphy.gif%3Fresize%3D300%252C167%26ssl%3D1" alt="Confused Trailer Park Boys GIF" width="300" height="167"&gt;&lt;/a&gt;&lt;/p&gt;

&lt;p&gt;Leave a comment if you do not agree &lt;a href="https://res.cloudinary.com/practicaldev/image/fetch/s--Q-Gs9eEo--/c_limit%2Cf_auto%2Cfl_progressive%2Cq_auto%2Cw_800/https://s.w.org/images/core/emoji/12.0.0-1/72x72/1f612.png" class="article-body-image-wrapper"&gt;&lt;img src="https://res.cloudinary.com/practicaldev/image/fetch/s--Q-Gs9eEo--/c_limit%2Cf_auto%2Cfl_progressive%2Cq_auto%2Cw_800/https://s.w.org/images/core/emoji/12.0.0-1/72x72/1f612.png" alt="😒" width="72" height="72"&gt;&lt;/a&gt;&lt;/p&gt;

&lt;p&gt;The post &lt;a href="https://khalifa.tn/why-react-is-so-popular/"&gt;Why React is so popular?&lt;/a&gt; appeared first on &lt;a href="https://khalifa.tn"&gt;C.Khalifa&lt;/a&gt;.&lt;/p&gt;

</description>
      <category>technology</category>
      <category>react</category>
    </item>
    <item>
      <title>[ImageMagick] Useful commands to process images</title>
      <dc:creator>Chokri K'</dc:creator>
      <pubDate>Fri, 30 Aug 2019 11:27:09 +0000</pubDate>
      <link>https://dev.to/chokri/imagemagick-useful-commands-to-process-images-20l0</link>
      <guid>https://dev.to/chokri/imagemagick-useful-commands-to-process-images-20l0</guid>
      <description>&lt;h2&gt;
  
  
  What is ImageMagick
&lt;/h2&gt;

&lt;p&gt;Many people thing that they need closed sources software to process photos, to create GIF animations, color management and transform images by sizing, croping and rotation.&lt;/p&gt;

&lt;p&gt;ImageMagick can do more then what we expect. It can also read and write images in a variety of &lt;a href="https://imagemagick.org/script/formats.php"&gt;formats&lt;/a&gt; (over 200) including PNG, JPEG, GIF, HEIC, TIFF, DPX, EXR, WebP, Postscript, PDF, and SVG.&lt;/p&gt;

&lt;p&gt;ImageMagick is free and open source. It’s available in linux, mac and windows using &lt;a href="http://www.mingw.org/"&gt;MinGW&lt;/a&gt; .&lt;br&gt;&lt;br&gt;
It’s also available in lib format  to make iOS, Windows, Linux Apps and as a php extension called “php7.x-imagick” to build server side image processing.&lt;/p&gt;

&lt;p&gt;After installing ImageMagick you should have access to all its tools.&lt;/p&gt;
&lt;h2&gt;
  
  
  Identify
&lt;/h2&gt;

&lt;p&gt;This tool is necessary to extract image information, specially with -verbose param this command will return all the information of the giving image. Here is an example:&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight plaintext"&gt;&lt;code&gt;identify -verbose beach-beautiful-bridge-449627.jpg
Image: beach-beautiful-bridge-449627.jpg
  Format: JPEG (Joint Photographic Experts Group JFIF format)
  Mime type: image/jpeg
  Class: DirectClass
  Geometry: 4032x3024+0+0
  Resolution: 72x72
  Print size: 56x42
  Units: PixelsPerInch
  Colorspace: sRGB
  Type: TrueColor
  Base type: Undefined
  Endianess: Undefined
  Depth: 8-bit
  Channel depth:
    Red: 8-bit
    Green: 8-bit
    Blue: 8-bit
  Channel statistics:
    Pixels: 12192768
    Red:
      min: 0  (0)
      max: 255 (1)
      mean: 70.7684 (0.277523)
      standard deviation: 67.0167 (0.262811)
      kurtosis: -0.402136
      skewness: 0.753672
      entropy: 0.888948
    Green:
      min: 0  (0)
      max: 255 (1)
      mean: 158.36 (0.62102)
      standard deviation: 58.2885 (0.228582)
      kurtosis: -0.658039
      skewness: -0.602582
      entropy: 0.962202
    Blue:
      min: 0  (0)
      max: 255 (1)
      mean: 209.097 (0.819987)
      standard deviation: 62.8143 (0.246331)
      kurtosis: 0.66187
      skewness: -1.37573
      entropy: 0.767422
  Image statistics:
    Overall:
      min: 0  (0)
      max: 255 (1)
      mean: 146.075 (0.572843)
      standard deviation: 62.7065 (0.245908)
      kurtosis: -1.24161
      skewness: -0.300494
      entropy: 0.872858
  Rendering intent: Perceptual
  Gamma: 0.454545
  Chromaticity:
    red primary: (0.64,0.33)
    green primary: (0.3,0.6)
    blue primary: (0.15,0.06)
    white point: (0.3127,0.329)
  Matte color: grey74
  Background color: white
  Border color: srgb(223,223,223)
  Transparent color: none
  Interlace: None
  Intensity: Undefined
  Compose: Over
  Page geometry: 4032x3024+0+0
  Dispose: Undefined
  Iterations: 0
  Compression: JPEG
  Quality: 73
  Orientation: Undefined
  Properties:
    date:create: 2019-08-30T09:12:12+00:00
    date:modify: 2019-05-03T13:10:37+00:00
    icc:copyright: Copyright (c) 1998 Hewlett-Packard Company
    icc:description: sRGB IEC61966-2.1
    icc:manufacturer: IEC http://www.iec.ch
    icc:model: IEC 61966-2.1 Default RGB colour space - sRGB
    jpeg:colorspace: 2
    jpeg:sampling-factor: 2x2,1x1,1x1
    signature: 567a0413315a5c6d41a4323b956452b234470449c7244448b2362c73411a0b57
  Profiles:
    Profile-icc: 3144 bytes
  Artifacts:
    verbose: true
  Tainted: False
  Filesize: 2.42723MiB
  Number pixels: 12.1928M
  Pixels per second: 57.8762MP
  User time: 0.200u
  Elapsed time: 0:01.210
  Version: ImageMagick 7.0.8-59 Q16 x86_64 2019-08-04 https://imagemagick.org
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;With this command line, we can extract colors, pixel, copyright and a lot of informations of a given image.&lt;/p&gt;

&lt;h2&gt;
  
  
  Inline Image resize
&lt;/h2&gt;

&lt;p&gt;This is the most used command on server size when uploading a gallery. Imagine that you copied a RAW images from an SDCard and you want to resize all the images to a specific ratio. you can run this command when you are on the folder:&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight plaintext"&gt;&lt;code&gt;cd ~/Images mkdir folder magick '\*.jpg[widthxheight]' folder/%03d.jpg
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;h2&gt;
  
  
  Inline Image Crop
&lt;/h2&gt;

&lt;p&gt;The same as resizing, croping need the X and Y to define witch part will start croping:&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight plaintext"&gt;&lt;code&gt;magick '\*.jpg' -crop widthxheight+x+y thumbnail%03d.jpg
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;h3&gt;
  
  
  Other Image processing commands
&lt;/h3&gt;

&lt;p&gt;There are a lot of commands that correct gamma, alpha, filter, blur, … etc of a given image. These commands are available with &lt;a href="https://imagemagick.org/script/convert.php"&gt;convert&lt;/a&gt; and &lt;a href="https://imagemagick.org/script/mogrify.php"&gt;mogrify&lt;/a&gt; tools. There is also -auto-gamma, -auto-level, -auto-threshold that accepts Kapur and OTSU methods. You have to know that you must have a minimum knowledge of image processing fundamentals that help you making a good magick commands and treatments. All these commands are well documented and explained here &lt;a href="https://imagemagick.org/script/command-line-options.php"&gt;https://imagemagick.org/script/command-line-options.php&lt;/a&gt;.&lt;/p&gt;

&lt;p&gt;The name of these commands are the sameof the theory behind so you can learn about it if you want. Don’t forget that ImageMagick is Open Source and FREE so you can find the codes that makes these function available to you.&lt;/p&gt;

&lt;p&gt;The post &lt;a href="https://khalifa.tn/imagemagick-useful-commands-to-process-images/"&gt;[ImageMagick] Useful commands to process images&lt;/a&gt; appeared first on &lt;a href="https://khalifa.tn"&gt;C.Khalifa&lt;/a&gt;.&lt;/p&gt;

</description>
      <category>image</category>
      <category>processing</category>
    </item>
    <item>
      <title>PHP 8: Introducing JIT</title>
      <dc:creator>Chokri K'</dc:creator>
      <pubDate>Wed, 01 May 2019 09:31:33 +0000</pubDate>
      <link>https://dev.to/chokri/php-8-introducing-jit-28f3</link>
      <guid>https://dev.to/chokri/php-8-introducing-jit-28f3</guid>
      <description>&lt;p&gt;Basically, the PHP scripts are compiled into instructions, which are called opcodes that are understandable to the machine. Opcodes are low-level, and hence faster to translate to machine code as compared to the original PHP code.&lt;/p&gt;

&lt;p&gt;&lt;a href="https://media.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fi2.wp.com%2Fkhalifa.tn%2Fwp-content%2Fuploads%2F2019%2F05%2Fphp-running.png%3Fresize%3D609%252C451%26ssl%3D1" class="article-body-image-wrapper"&gt;&lt;img src="https://media.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fi2.wp.com%2Fkhalifa.tn%2Fwp-content%2Fuploads%2F2019%2F05%2Fphp-running.png%3Fresize%3D609%252C451%26ssl%3D1"&gt;&lt;/a&gt;&lt;/p&gt;

&lt;p&gt;This stage of execution is called compile time. These opcodes are then executed by the Zend VM in the runtime stage.&lt;/p&gt;

&lt;p&gt;JIT (Just In Time) is being implemented as an almost independent part of OPcache, an extension to cache the opcodes so that compilation happens only when it is required. In PHP, JIT will treat the instructions generated for the Zend VM as the intermediate representation. It will then generate an architecture dependent machine code so that the host of your code is no longer the Zend VM, but the CPU directly&lt;/p&gt;

&lt;h3&gt;
  
  
  Why JIT?
&lt;/h3&gt;

&lt;p&gt;Many improvements have been done to PHP since its 7.0 version including optimizations for HashTable, specializations in the Zend VM for certain opcodes, specializations in the compiler for certain sequences, and many more. After so many improvements, now PHP has reached the extent of its ability to be improved any further.&lt;/p&gt;

&lt;p&gt;So, JIT is a technique that will compile parts of the code at runtime, so that the compiled version can be used instead.(Just In Time)&lt;/p&gt;

&lt;h3&gt;
  
  
  PHP comparing to C/Ruby/Python
&lt;/h3&gt;

&lt;p&gt;Adding support for JIT in PHP will allow its use in scenarios for which it is not even considered today, PHP is not that HTML Templating but a programming language comparing to Ruby, Python and Java.&lt;/p&gt;

&lt;h3&gt;
  
  
  Faster  and more secure
&lt;/h3&gt;

&lt;p&gt;With JIT support, the core team will be able to develop built-in functions in PHP instead of C without any huge performance penalty. This will make PHP less susceptible to memory management, overflows, and other similar issues associated with C-based development.&lt;/p&gt;

&lt;p&gt;According to stitcher, &lt;a href="https://stitcher.io/blog/new-in-php-74" rel="noopener noreferrer"&gt;PHP 7.4&lt;/a&gt; will introduce JIT. The release date is probably around December 2019, but not yet confirmed. Though there is no official announcement about the release schedule of PHP 8, many are speculating its release in late 2021.&lt;/p&gt;

&lt;p&gt;The post &lt;a href="https://khalifa.tn/php-8-introducing-jit/" rel="noopener noreferrer"&gt;PHP 8: Introducing JIT&lt;/a&gt; appeared first on &lt;a href="https://khalifa.tn" rel="noopener noreferrer"&gt;C.Khalifa&lt;/a&gt;.&lt;/p&gt;

</description>
      <category>technology</category>
      <category>php</category>
    </item>
    <item>
      <title>日本語を学ぶ：私のコツ</title>
      <dc:creator>Chokri K'</dc:creator>
      <pubDate>Sun, 21 Apr 2019 13:23:20 +0000</pubDate>
      <link>https://dev.to/chokri/-eg9</link>
      <guid>https://dev.to/chokri/-eg9</guid>
      <description>&lt;h2&gt;
  
  
  Learning Japanese: My Tricks
&lt;/h2&gt;

&lt;p&gt;&lt;em&gt;Don’t worry, I translated the title!&lt;/em&gt;&lt;/p&gt;

&lt;p&gt;Since many years, I started learning Japanese at school, It was a fail for me because I didn’t practice it and I forgot everything. Then every time I retry, It becomes hard to me until I found the best practice to learn it.&lt;/p&gt;

&lt;p&gt;First, I installed this application.&lt;/p&gt;

&lt;p&gt;&lt;a href="https://res.cloudinary.com/practicaldev/image/fetch/s--VBMLcIJW--/c_limit%2Cf_auto%2Cfl_progressive%2Cq_auto%2Cw_800/https://i0.wp.com/khalifa.tn/wp-content/uploads/2018/12/Screenshot_20181209-004725.png%3Fresize%3D194%252C344%26ssl%3D1" class="article-body-image-wrapper"&gt;&lt;img src="https://res.cloudinary.com/practicaldev/image/fetch/s--VBMLcIJW--/c_limit%2Cf_auto%2Cfl_progressive%2Cq_auto%2Cw_800/https://i0.wp.com/khalifa.tn/wp-content/uploads/2018/12/Screenshot_20181209-004725.png%3Fresize%3D194%252C344%26ssl%3D1" alt="Hiragana pro" width="194" height="344"&gt;&lt;/a&gt;&lt;/p&gt;

&lt;p&gt;Hiragana Pro &lt;a href="https://play.google.com/store/apps/details?id=com.myapps.hiragana"&gt;https://play.google.com/store/apps/details?id=com.myapps.hiragana&lt;/a&gt;&lt;/p&gt;




&lt;p&gt;This is thanks to the application Hiragana Pro. Its purpose is to show you the letters randomly from the beginning until you can memorize them.&lt;/p&gt;

&lt;p&gt;Obviously it takes time. That’s why I took it as a challenge.&lt;/p&gt;

&lt;p&gt;After learning all Hiragana caracters, we have to learn Katakana too, because these letters are used to write our names, and the international things for exemple : “コンピューター” (Computer)&lt;/p&gt;

&lt;p&gt;It’s not easy as we thought but after a while I start to take interest in Kanji.&lt;/p&gt;

&lt;p&gt;… And this is a hardest things I’m trying to resolve.&lt;br&gt;&lt;br&gt;
The Kanjis are not letters but rather a meaning. A meaning that The Japanese use to define the sense of the sentence and at the same time they pronounce Kanjis as Chinese.&lt;/p&gt;

&lt;p&gt;My first Kanji I learned is 私. it is (Watashi == ‘I’) but in a way too polite. We use 私 as the beginning of the sentence to indicate that the subject is the “me”.&lt;/p&gt;

&lt;p&gt;&lt;a href="https://res.cloudinary.com/practicaldev/image/fetch/s--2EFi1pyN--/c_limit%2Cf_auto%2Cfl_progressive%2Cq_auto%2Cw_800/https://i2.wp.com/khalifa.tn/wp-content/uploads/2018/12/Capture-d%25E2%2580%2599e%25CC%2581cran-2018-12-09-a%25CC%2580-1.11.17-AM.png%3Fresize%3D283%252C100%26ssl%3D1" class="article-body-image-wrapper"&gt;&lt;img src="https://res.cloudinary.com/practicaldev/image/fetch/s--2EFi1pyN--/c_limit%2Cf_auto%2Cfl_progressive%2Cq_auto%2Cw_800/https://i2.wp.com/khalifa.tn/wp-content/uploads/2018/12/Capture-d%25E2%2580%2599e%25CC%2581cran-2018-12-09-a%25CC%2580-1.11.17-AM.png%3Fresize%3D283%252C100%26ssl%3D1" alt="ExempleJaponais" width="283" height="100"&gt;&lt;/a&gt;I am a student&lt;/p&gt;

&lt;p&gt;That’s it.&lt;/p&gt;

&lt;p&gt;The post &lt;a href="https://khalifa.tn/%e6%97%a5%e6%9c%ac%e8%aa%9e%e3%82%92%e5%ad%a6%e3%81%b6%ef%bc%9a%e7%a7%81%e3%81%ae%e3%82%b3%e3%83%84/"&gt;日本語を学ぶ：私のコツ&lt;/a&gt; appeared first on &lt;a href="https://khalifa.tn"&gt;C.Khalifa&lt;/a&gt;.&lt;/p&gt;

</description>
      <category>japanese</category>
    </item>
    <item>
      <title>What ‘use strict’ means for in JavaScript</title>
      <dc:creator>Chokri K'</dc:creator>
      <pubDate>Wed, 17 Apr 2019 08:19:12 +0000</pubDate>
      <link>https://dev.to/chokri/what-use-strict-means-for-in-javascript-oma</link>
      <guid>https://dev.to/chokri/what-use-strict-means-for-in-javascript-oma</guid>
      <description>&lt;p&gt;“strict mode”;&lt;/p&gt;

&lt;p&gt;It’s a ECMAScript 5 feature that prevents certain actions from being taken and throws more exceptions in a JavaScript code.&lt;/p&gt;

&lt;p&gt;The strict mode is necessary if you have a complex code to write. It introduces better error-checking, If you have a calculating algorithm.&lt;br&gt;&lt;br&gt;
Without this mode you can write console.log(Infinity = 0) and there is no problem with that. This will return 0 as inspected and Error “TypeError: “Infinity” is read-only”&lt;/p&gt;

&lt;p&gt;We can use this feature into a function. For example:&lt;/p&gt;

&lt;blockquote&gt;

&lt;pre class="highlight plaintext"&gt;&lt;code&gt;// Non-strict code... (function(){ "use strict"; // Define your library strictly... })(); // Non-strict code...
&lt;/code&gt;&lt;/pre&gt;

&lt;/blockquote&gt;

&lt;p&gt;But, if you activate it you’ll see a lot of problems on the console. To avoid that, try to write a clean code.&lt;/p&gt;

&lt;p&gt;The post &lt;a href="https://khalifa.tn/what-use-strict-means-for-in-javascript/"&gt;What ‘use strict’ means for in JavaScript&lt;/a&gt; appeared first on &lt;a href="https://khalifa.tn"&gt;C.Khalifa&lt;/a&gt;.&lt;/p&gt;

</description>
      <category>general</category>
      <category>public</category>
      <category>technology</category>
      <category>javascript</category>
    </item>
    <item>
      <title>This is why I use KeyCloak?</title>
      <dc:creator>Chokri K'</dc:creator>
      <pubDate>Sun, 24 Mar 2019 23:04:32 +0000</pubDate>
      <link>https://dev.to/chokri/this-is-why-i-use-keycloak-2a2b</link>
      <guid>https://dev.to/chokri/this-is-why-i-use-keycloak-2a2b</guid>
      <description>&lt;p&gt;Hello everyone ! Today i’m going to explain to you how you can save time when securing your web services.&lt;/p&gt;

&lt;p&gt;As developer, I always start new project thinking about User registration, Email Confirmations and Authentication with multiple roles and accesses. It’s a huge task for a freelancer that want to concentrate on the main tasks of the project leaving this things away for a moment.&lt;/p&gt;

&lt;p&gt;When I start a PHP project, I always use&lt;a href="https://github.com/cakedc/users" rel="noopener noreferrer"&gt;Users&lt;/a&gt; plugin made by&lt;a href="https://cakedc.com" rel="noopener noreferrer"&gt;CakeDC&lt;/a&gt;. This tool is amazing and allow us to easily set Social Providers Login/register like Twitter, Google and Facebook.&lt;/p&gt;

&lt;p&gt;But, what about Node JS projects? I use Passport JS and this is a great package that allow to secure our applications.&lt;/p&gt;

&lt;p&gt;Recently I worked in a big project and I learned many things about how we can identify users and how can user login in from any Identity provider.&lt;/p&gt;

&lt;p&gt;&lt;strong&gt;What is KeyCloak?&lt;/strong&gt;&lt;/p&gt;

&lt;p&gt;&lt;a href="https://media.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fi2.wp.com%2Fkhalifa.tn%2Fwp-content%2Fuploads%2F2019%2F03%2F1_WWDwg84fYnWVuonCZlsG4Q.png%3Fresize%3D646%252C189%26ssl%3D1" class="article-body-image-wrapper"&gt;&lt;img src="https://media.dev.to/dynamic/image/width=800%2Cheight=%2Cfit=scale-down%2Cgravity=auto%2Cformat=auto/https%3A%2F%2Fi2.wp.com%2Fkhalifa.tn%2Fwp-content%2Fuploads%2F2019%2F03%2F1_WWDwg84fYnWVuonCZlsG4Q.png%3Fresize%3D646%252C189%26ssl%3D1"&gt;&lt;/a&gt;&lt;/p&gt;

&lt;p&gt;It’s a Java solution created by &lt;a href="https://redhat.com" rel="noopener noreferrer"&gt;Red Hat&lt;/a&gt; to manage authentication and authorisation. We can run it on a different Java Servers like Tomcat, JBoss and Jelly.. We can configure its Datasource like MySQL, PostGres or Oracle Database. It support H2 database system too.&lt;/p&gt;

&lt;p&gt;KeyCloak supports OpenID-Connect, Oauth and SAML Protocol. Its main functionality is to provide a single sign on in many applications at the same time. For example; when you connect to Youtube, you are connected to Gmail in the same time right? But when you did connect to other application like adsense you are not connected automatically.&lt;/p&gt;

&lt;p&gt;Think about it, when we sign in on Youtube we are redirected to Google account page and not a Youtube Login page, and that’s mean that Google Account is the Identity server of all Google products.&lt;/p&gt;

&lt;p&gt;Imagine you are creating a web application based on Micro-services Architecture. How can you sign the user on different services?&lt;/p&gt;

&lt;p&gt;&lt;strong&gt;Many Realm in the same time&lt;/strong&gt;&lt;/p&gt;

&lt;p&gt;Imagine a new application is provided on Google Ex: GPizza Eat, if I have a Google Account Do I have access to this new App? Unfortunately no. I have to subscribe to this app as the same technique when we give access to external Google application to access our email address.&lt;/p&gt;

&lt;p&gt;So every application can be hosted in a different server, written with a different language. These applications have a different list of users.&lt;/p&gt;

&lt;p&gt;In KeyCloak these different application are called Realm, every Realm contain its users and provide different clients (applications)&lt;/p&gt;

&lt;p&gt;KeyCloak must be installed in a High Availability system, like Kubernetes, Docker Swarm. It must run under HTTPS server, in this case I recommand installing Nginx and I configuring it to reverse proxy 443 port to 8443 (KeyCloak).&lt;/p&gt;

&lt;p&gt;The post &lt;a href="https://khalifa.tn/this-is-why-i-use-keycloak/" rel="noopener noreferrer"&gt;This is why I use KeyCloak?&lt;/a&gt; appeared first on &lt;a href="https://khalifa.tn" rel="noopener noreferrer"&gt;C.Khalifa&lt;/a&gt;.&lt;/p&gt;

</description>
      <category>technology</category>
      <category>security</category>
      <category>microservices</category>
    </item>
    <item>
      <title>Gitlab-CI using Panther and Symfony 4</title>
      <dc:creator>Chokri K'</dc:creator>
      <pubDate>Tue, 09 Oct 2018 10:14:37 +0000</pubDate>
      <link>https://dev.to/chokri/gitlab-ci-using-panther-and-symfony-4-4k10</link>
      <guid>https://dev.to/chokri/gitlab-ci-using-panther-and-symfony-4-4k10</guid>
      <description>&lt;p&gt;I tried to test my Symfony 4.1 app using gitlab-ci. Basically, when we Test PHP application we require php-cli docker image to execute composer install, phpunit.&lt;br&gt;&lt;br&gt;
But in this case I have a node packages to install, a React App in the front to test and a Rest API to test with my React Application.&lt;/p&gt;

&lt;p&gt;I created a simple Symfony 4.1 App using React Routes in front and I execute a fetch to get a JSON from ApiController.&lt;/p&gt;

&lt;p&gt;I made a TestCase using Panther to test it locally and it works perfectly.&lt;/p&gt;

&lt;p&gt;It tooks 9 secondes because in the controller I wrote sleep 8 secondes before returning the Response. &lt;/p&gt;

&lt;p&gt;Then, I want to test my app using Gitlab-CI, when I push an update I want to be sure that everything is fine and I can safely deploy my app on production.&lt;/p&gt;

&lt;p&gt;I write a gitlab-ci to test the app, and it fails… it fails… it fails… I check the log and I try… Finally I decided to write my own Docker image and test my app with it.&lt;/p&gt;

&lt;p&gt;I made this &lt;a href="https://hub.docker.com/r/chokri/phpnode/"&gt;Docker image&lt;/a&gt; base on Ubuntu 18.04. It contains PHP 7.2 andNode JS.&lt;br&gt;&lt;br&gt;
To be able to run Panther Unit Tests, we need to install 3 packages, (ZIP, Libnss3 and chromium-browser). All these stuffs are available in one place. The problem is that the size of the image is about 1.18GB !!&lt;/p&gt;

&lt;p&gt;With this docker image I’m now able to run CI tests on gitlab.&lt;/p&gt;

&lt;p&gt;&lt;a href="https://res.cloudinary.com/practicaldev/image/fetch/s--lCK9rQJS--/c_limit%2Cf_auto%2Cfl_progressive%2Cq_auto%2Cw_800/https://i1.wp.com/khalifa.tn/wp-content/uploads/2018/10/Capture-d%25E2%2580%2599e%25CC%2581cran-2018-10-09-a%25CC%2580-11.04.36-AM.png%3Fw%3D646%26ssl%3D1" class="article-body-image-wrapper"&gt;&lt;img src="https://res.cloudinary.com/practicaldev/image/fetch/s--lCK9rQJS--/c_limit%2Cf_auto%2Cfl_progressive%2Cq_auto%2Cw_800/https://i1.wp.com/khalifa.tn/wp-content/uploads/2018/10/Capture-d%25E2%2580%2599e%25CC%2581cran-2018-10-09-a%25CC%2580-11.04.36-AM.png%3Fw%3D646%26ssl%3D1" alt="" width="646" height="389"&gt;&lt;/a&gt;&lt;/p&gt;

&lt;p&gt;&lt;a href="https://res.cloudinary.com/practicaldev/image/fetch/s--qNp4toKF--/c_limit%2Cf_auto%2Cfl_progressive%2Cq_auto%2Cw_800/https://i0.wp.com/khalifa.tn/wp-content/uploads/2018/10/Capture-d%25E2%2580%2599e%25CC%2581cran-2018-10-09-a%25CC%2580-11.05.57-AM.png%3Fw%3D646%26ssl%3D1" class="article-body-image-wrapper"&gt;&lt;img src="https://res.cloudinary.com/practicaldev/image/fetch/s--qNp4toKF--/c_limit%2Cf_auto%2Cfl_progressive%2Cq_auto%2Cw_800/https://i0.wp.com/khalifa.tn/wp-content/uploads/2018/10/Capture-d%25E2%2580%2599e%25CC%2581cran-2018-10-09-a%25CC%2580-11.05.57-AM.png%3Fw%3D646%26ssl%3D1" alt="" width="646" height="306"&gt;&lt;/a&gt;&lt;/p&gt;

&lt;p&gt;The post &lt;a href="https://khalifa.tn/gitlab-ci-using-panther-and-symfony-4/"&gt;Gitlab-CI using Panther and Symfony 4&lt;/a&gt; appeared first on &lt;a href="https://khalifa.tn"&gt;C.Khalifa&lt;/a&gt;.&lt;/p&gt;

</description>
      <category>technology</category>
      <category>ci</category>
      <category>gitlab</category>
      <category>panther</category>
    </item>
  </channel>
</rss>
