sharique's bloghttp://openahmed.com/blogs/sharique
enOpenSuse Leap 42.3 reviewhttp://openahmed.com/blog/opensuse-leap-423-review
<div class="field field-name-body field-type-text-with-summary field-label-hidden view-mode-rss"><div class="field-items"><div class="field-item even" property="content:encoded"><p>On July 26, OpenSuse project release the latest version of OpenSuse distribution – OpenSuse Leap 42.3. It is powered by LTS kernel 4.4 with many features back ported from newer release, particularly related to latest hardware support. Among the key packages are gcc 4.8.5, KDE Plasma 5.8 LTS and Gnome version 3.20. Other desktop environment like XFCE or LxQt can be downloaded from repos. It shared the base with Suse Enterprise (SLE) 12 Service pack 3, so it is extremely stable and secure. Firefox version is 52 ESR (ESR is enterprise release channel) and LibreOffice 5.3.<br />
Installer is same old proved and tested Yast based installer, nothing much changed here. For installation, I downloaded DVD which little over 4.3 GB. I created bootable USB stick using rufus (<a href="https://rufus.akeo.ie">https://rufus.akeo.ie</a>) utility. I took me around 30 mins to install with default package selection. I was expecting it to be faster as I was using USB 3.0 stick.<br />
Except wifi adapter all hardware on my carrizo laptop is detected a properly. The wifi adapter is Broadcom 802.11ac and there is not wifi driver for Linux from Broadcom. My laptop is two years old and it was not latest model when bought it. It is really sad that Broadcom ignores its Linux user base. I’ve TP-Link USB wifi adapter also, which is not detected by Leap but works fine in Tumbleweed. Anybody facing similar issues I recommend them to either install latest Kernel:stable repo or switch to tumbleweed.<br />
When booting into the newly installed OS I saw few error messages related to amdgpu. In leap kernel version is 4.4 with back ported patches. I’m also running OpenSuse tumbleweed with kernel 4.12 in which I don’t see such messages. Seems like all driver features are not backported. Please note that I didn’t find any issue while using Leap, I didn’t tested gaming yet. Performance is good and feels very stable. I didn’t face any issues in my few days of usage.<br />
Now I installed my favorite packages like google chrome, opera, vlc, ffmpeg and kodi. For google chrome I downloaded it from official site. Opera from non-oss update repo, it has slightly older version but it is fine for me. I used packman repo for installing vlc, ffmpeg and kodi. For vlc to work perfectly don’t forget to install vlc-codes packages as some videos will not be able to play, also make sure install vlc and vlc-codecs from same repo (prefer packman as it has more codecs supported packages).<br />
Apart from the above mentioned hardware related issue new OpenSuse leap release very stable and solid release. The goal to make openSUSE based on SLE to provide enterprise class desktop to all users. It is highly recommended for user who are looking for stable desktop. For those who are looking for latest stable version of packages Tumblweed is the right option, I’m using it from past 6 months, didn’t find issue.<br />
The next version of OpenSuse won’t be called the Leap, will be based on Enterprise edition, Next version of SLE will be 15 so next OpenSuse will called OpenSuse 15.0.</p>
</div></div></div><section class="field field-name-field-tags field-type-taxonomy-term-reference field-label-above view-mode-rss"><h2 class="field-label">Tags:&nbsp;</h2><ul class="field-items"><li class="field-item even"><a href="/tags/opensuse" typeof="skos:Concept" property="rdfs:label skos:prefLabel" datatype="">OpenSuse</a></li></ul></section><ul class="links inline"><li class="service-links-delicious first"><a href="http://del.icio.us/post?url=http%3A//openahmed.com/blog/opensuse-leap-423-review&amp;title=OpenSuse%20Leap%2042.3%20review" title="Bookmark this post on del.icio.us." class="service-links-delicious" rel="nofollow" target="_blank"><img typeof="foaf:Image" class="image-style-none" src="http://openahmed.com/sites/all/modules/contrib/service_links/images/delicious.png" alt="del.icio.us" /></a></li><li class="service-links-facebook"><a href="http://www.facebook.com/sharer.php?u=http%3A//openahmed.com/blog/opensuse-leap-423-review&amp;t=OpenSuse%20Leap%2042.3%20review" title="Share on Facebook." class="service-links-facebook" rel="nofollow" target="_blank"><img typeof="foaf:Image" class="image-style-none" src="http://openahmed.com/sites/all/modules/contrib/service_links/images/facebook.png" alt="Facebook" /></a></li><li class="service-links-google"><a href="http://www.google.com/bookmarks/mark?op=add&amp;bkmk=http%3A//openahmed.com/blog/opensuse-leap-423-review&amp;title=OpenSuse%20Leap%2042.3%20review" title="Bookmark this post on Google." class="service-links-google" rel="nofollow" target="_blank"><img typeof="foaf:Image" class="image-style-none" src="http://openahmed.com/sites/all/modules/contrib/service_links/images/google.png" alt="Google" /></a></li><li class="service-links-slashdot"><a href="http://slashdot.org/bookmark.pl?url=http%3A//openahmed.com/blog/opensuse-leap-423-review&amp;title=OpenSuse%20Leap%2042.3%20review" title="Bookmark this post on SlashDot" class="service-links-slashdot" rel="nofollow" target="_blank"><img typeof="foaf:Image" class="image-style-none" src="http://openahmed.com/sites/all/modules/contrib/service_links/images/slashdot.png" alt="SlashDot" /></a></li><li class="service-links-twitter"><a href="http://twitter.com/share?url=http%3A//openahmed.com/node/17&amp;text=OpenSuse%20Leap%2042.3%20review" title="Share this on Twitter" class="service-links-twitter" rel="nofollow" target="_blank"><img typeof="foaf:Image" class="image-style-none" src="http://openahmed.com/sites/all/modules/contrib/service_links/images/twitter.png" alt="Twitter" /></a></li><li class="service-links-yahoo last"><a href="http://bookmarks.yahoo.com/myresults/bookmarklet?u=http%3A//openahmed.com/blog/opensuse-leap-423-review&amp;t=OpenSuse%20Leap%2042.3%20review" title="Bookmark this post on Yahoo." class="service-links-yahoo" rel="nofollow" target="_blank"><img typeof="foaf:Image" class="image-style-none" src="http://openahmed.com/sites/all/modules/contrib/service_links/images/yahoo.png" alt="Yahoo" /></a></li></ul>Fri, 20 Oct 2017 05:42:37 +0000sharique17 at http://openahmed.comhttp://openahmed.com/blog/opensuse-leap-423-review#commentsConfigure Atom editor for Drupal developmenthttp://openahmed.com/blog/configure-atom-editor-drupal-development
<div class="field field-name-body field-type-text-with-summary field-label-hidden view-mode-rss"><div class="field-items"><div class="field-item even" property="content:encoded"><p><a href="https://atom.io" target="_blank">Atom editor (or just Atom)</a> is free and open source text and code editor build by GitHub. It is build using Chromium, nodejs, CoffeScript and Less. There are few other editors build using nodejs, second most popular project is <a href="http://brackets.io" target="-_blank">Brackets</a>. I've tried both and found Atom stable among two. Another advantage Atom has more plugins than Brackets. Recently I'm started to using it as alternate for Sublime Text.<br />
It has many plugin for Drupal also. I'm using following plugins</p>
<ul><li>
<a href="https://atom.io/packages/drupal" target="_blank"> Drupal </a> - It provides Drupal snippets, filetypes association and hotkeys. Currently it only provide Drupal 7 snippets.
</li>
<li><a href="https://atom.io/packages/linter-drupalcs" target="_blank">Linter Drupalcs </a> - It checks the code for Drupal coding standrd (aka drupalcs) errors in the code. To configure this make sure code sniffer and coder module is installed and manually provide path for Drupal coding standard file.
</li>
<li><a href="https://atom.io/packages/terminal-plus" target="_blank"> Terminal plus </a> It provides the terminal inside Atom editor window, it is very useful running commands like drush without moving away from code.</li>
<li> <a href="https://atom.io/packages/color-picker" target="_blank"> Color picker</a> - It provides the color picker while css editing. </li>
<li><a href="https://atom.io/packages/atom-autocomplete-php" target="_blank"> Atom autocomplete Php</a> - It provides autocomplete functionality for PHP for composer base projects. Since it uses composer, it useful for Drupal 8 projects. </li>
</ul></div></div></div><section class="field field-name-field-tags field-type-taxonomy-term-reference field-label-above view-mode-rss"><h2 class="field-label">Tags:&nbsp;</h2><ul class="field-items"><li class="field-item even"><a href="/tags/drupal" typeof="skos:Concept" property="rdfs:label skos:prefLabel" datatype="">Drupal</a></li><li class="field-item odd"><a href="/tags/atom" typeof="skos:Concept" property="rdfs:label skos:prefLabel" datatype="">atom</a></li></ul></section><ul class="links inline"><li class="service-links-delicious first"><a href="http://del.icio.us/post?url=http%3A//openahmed.com/blog/configure-atom-editor-drupal-development&amp;title=Configure%20Atom%20editor%20for%20Drupal%20development" title="Bookmark this post on del.icio.us." class="service-links-delicious" rel="nofollow" target="_blank"><img typeof="foaf:Image" class="image-style-none" src="http://openahmed.com/sites/all/modules/contrib/service_links/images/delicious.png" alt="del.icio.us" /></a></li><li class="service-links-facebook"><a href="http://www.facebook.com/sharer.php?u=http%3A//openahmed.com/blog/configure-atom-editor-drupal-development&amp;t=Configure%20Atom%20editor%20for%20Drupal%20development" title="Share on Facebook." class="service-links-facebook" rel="nofollow" target="_blank"><img typeof="foaf:Image" class="image-style-none" src="http://openahmed.com/sites/all/modules/contrib/service_links/images/facebook.png" alt="Facebook" /></a></li><li class="service-links-google"><a href="http://www.google.com/bookmarks/mark?op=add&amp;bkmk=http%3A//openahmed.com/blog/configure-atom-editor-drupal-development&amp;title=Configure%20Atom%20editor%20for%20Drupal%20development" title="Bookmark this post on Google." class="service-links-google" rel="nofollow" target="_blank"><img typeof="foaf:Image" class="image-style-none" src="http://openahmed.com/sites/all/modules/contrib/service_links/images/google.png" alt="Google" /></a></li><li class="service-links-slashdot"><a href="http://slashdot.org/bookmark.pl?url=http%3A//openahmed.com/blog/configure-atom-editor-drupal-development&amp;title=Configure%20Atom%20editor%20for%20Drupal%20development" title="Bookmark this post on SlashDot" class="service-links-slashdot" rel="nofollow" target="_blank"><img typeof="foaf:Image" class="image-style-none" src="http://openahmed.com/sites/all/modules/contrib/service_links/images/slashdot.png" alt="SlashDot" /></a></li><li class="service-links-twitter"><a href="http://twitter.com/share?url=http%3A//openahmed.com/node/16&amp;text=Configure%20Atom%20editor%20for%20Drupal%20development" title="Share this on Twitter" class="service-links-twitter" rel="nofollow" target="_blank"><img typeof="foaf:Image" class="image-style-none" src="http://openahmed.com/sites/all/modules/contrib/service_links/images/twitter.png" alt="Twitter" /></a></li><li class="service-links-yahoo last"><a href="http://bookmarks.yahoo.com/myresults/bookmarklet?u=http%3A//openahmed.com/blog/configure-atom-editor-drupal-development&amp;t=Configure%20Atom%20editor%20for%20Drupal%20development" title="Bookmark this post on Yahoo." class="service-links-yahoo" rel="nofollow" target="_blank"><img typeof="foaf:Image" class="image-style-none" src="http://openahmed.com/sites/all/modules/contrib/service_links/images/yahoo.png" alt="Yahoo" /></a></li></ul>Mon, 30 May 2016 06:55:32 +0000sharique16 at http://openahmed.comhttp://openahmed.com/blog/configure-atom-editor-drupal-development#commentsUsing disqus for comments on the sitehttp://openahmed.com/blog/using-disqus-comments-site
<div class="field field-name-body field-type-text-with-summary field-label-hidden view-mode-rss"><div class="field-items"><div class="field-item even" property="content:encoded"><p>Few months back I started using <a href="https://disqus.com/" target="_blank">disqus</a> commenting system on my site, so far my experience is good. Disqus is very is easy in install and configure. Download and install <a href="https://www.drupal.org/project/disqus" target="_blank">disqus module</a> from Drupal.org enable it, get api key for your site from Disqus.com and that's it.<br />
For end user the biggest advantage it that you don't have to create separate account for each site, you can comment using existing disqus account. It really save a lot of time for end user as well.<br />
Comment moderation is also simple, disqus has very nice user interface for moderation.</p>
</div></div></div><section class="field field-name-field-tags field-type-taxonomy-term-reference field-label-above view-mode-rss"><h2 class="field-label">Tags:&nbsp;</h2><ul class="field-items"><li class="field-item even"><a href="/tags/disqus" typeof="skos:Concept" property="rdfs:label skos:prefLabel" datatype="">disqus</a></li></ul></section><ul class="links inline"><li class="service-links-delicious first"><a href="http://del.icio.us/post?url=http%3A//openahmed.com/blog/using-disqus-comments-site&amp;title=Using%20disqus%20for%20comments%20on%20the%20site" title="Bookmark this post on del.icio.us." class="service-links-delicious" rel="nofollow" target="_blank"><img typeof="foaf:Image" class="image-style-none" src="http://openahmed.com/sites/all/modules/contrib/service_links/images/delicious.png" alt="del.icio.us" /></a></li><li class="service-links-facebook"><a href="http://www.facebook.com/sharer.php?u=http%3A//openahmed.com/blog/using-disqus-comments-site&amp;t=Using%20disqus%20for%20comments%20on%20the%20site" title="Share on Facebook." class="service-links-facebook" rel="nofollow" target="_blank"><img typeof="foaf:Image" class="image-style-none" src="http://openahmed.com/sites/all/modules/contrib/service_links/images/facebook.png" alt="Facebook" /></a></li><li class="service-links-google"><a href="http://www.google.com/bookmarks/mark?op=add&amp;bkmk=http%3A//openahmed.com/blog/using-disqus-comments-site&amp;title=Using%20disqus%20for%20comments%20on%20the%20site" title="Bookmark this post on Google." class="service-links-google" rel="nofollow" target="_blank"><img typeof="foaf:Image" class="image-style-none" src="http://openahmed.com/sites/all/modules/contrib/service_links/images/google.png" alt="Google" /></a></li><li class="service-links-slashdot"><a href="http://slashdot.org/bookmark.pl?url=http%3A//openahmed.com/blog/using-disqus-comments-site&amp;title=Using%20disqus%20for%20comments%20on%20the%20site" title="Bookmark this post on SlashDot" class="service-links-slashdot" rel="nofollow" target="_blank"><img typeof="foaf:Image" class="image-style-none" src="http://openahmed.com/sites/all/modules/contrib/service_links/images/slashdot.png" alt="SlashDot" /></a></li><li class="service-links-twitter"><a href="http://twitter.com/share?url=http%3A//openahmed.com/node/15&amp;text=Using%20disqus%20for%20comments%20on%20the%20site" title="Share this on Twitter" class="service-links-twitter" rel="nofollow" target="_blank"><img typeof="foaf:Image" class="image-style-none" src="http://openahmed.com/sites/all/modules/contrib/service_links/images/twitter.png" alt="Twitter" /></a></li><li class="service-links-yahoo last"><a href="http://bookmarks.yahoo.com/myresults/bookmarklet?u=http%3A//openahmed.com/blog/using-disqus-comments-site&amp;t=Using%20disqus%20for%20comments%20on%20the%20site" title="Bookmark this post on Yahoo." class="service-links-yahoo" rel="nofollow" target="_blank"><img typeof="foaf:Image" class="image-style-none" src="http://openahmed.com/sites/all/modules/contrib/service_links/images/yahoo.png" alt="Yahoo" /></a></li></ul>Sun, 08 May 2016 09:58:24 +0000sharique15 at http://openahmed.comhttp://openahmed.com/blog/using-disqus-comments-site#commentsHow I do the development setuphttp://openahmed.com/blog/how-i-do-development-setup
<div class="field field-name-body field-type-text-with-summary field-label-hidden view-mode-rss"><div class="field-items"><div class="field-item even" property="content:encoded"><p>In the following blog post I'm going to tell you how I set up my development environment. I hope people will find it useful.</p>
<p> Currently my work is mostly focused on drupal, but I've worked with C++, C# and Asp.net. First I'm going to tell you about general setup which is common for all technologies, after that I'll tell you about items specific to technologies.</p>
<p><strong>Folder structure</strong><br />
I keep all my projects inside "Projects" folder in home, some distros have it by default, if it not don't exists create one. In side projects folder I've one folder for each technology and inside this folder fror each client/project, for example for a project xyz using drupal folder will be "/home/sharique/Projects/drupal/xyz". Inside this I've some common folders like files (for various resources, like documents, site files, etc), tmp (everything uncategorized), docs ( for project docs like documentation, requirement docs, wire-frame, etc) and project repos. If there are many repos in project it is better to have a repos folder, because for a large projects over the period you end up creating many folders for different purposes. Even for web projects I follow same structure and create either virtual host or symlink inside www folder.</p>
<p><strong>IDE</strong><br />
I mostly used Netbeans and sublime text for most of my drupal work. I also started using PhpStorm in office as my company have licenses. Netbeans has good support for drupal 7, there is a nice plug-in (<a href="https://github.com/HollyIT/NBDrupalDevel">https://github.com/HollyIT/NBDrupalDevel</a>) but support for drupal in PhpStorm is far better. Here is a blog post if you want to use it for drupal development (<a href="http://alexrayu.com/blog/benefits-netbeans-drupal-ide">http://alexrayu.com/blog/benefits-netbeans-drupal-ide</a>). IDE make doing things easier, either is formatting a file or building a projects or debugging. My top reason for using an IDE is code completion and syntax errors and other warnings. IDE also uses a lot of resource, so for small things it does not make sense to use it. For small tasks I use Sublime Text.</p>
</div></div></div><section class="field field-name-field-tags field-type-taxonomy-term-reference field-label-above view-mode-rss"><h2 class="field-label">Tags:&nbsp;</h2><ul class="field-items"><li class="field-item even"><a href="/tags/development" typeof="skos:Concept" property="rdfs:label skos:prefLabel" datatype="">development</a></li><li class="field-item odd"><a href="/tags/drupal" typeof="skos:Concept" property="rdfs:label skos:prefLabel" datatype="">Drupal</a></li><li class="field-item even"><a href="/tags/netbeans" typeof="skos:Concept" property="rdfs:label skos:prefLabel" datatype="">Netbeans</a></li><li class="field-item odd"><a href="/tags/phpstorm" typeof="skos:Concept" property="rdfs:label skos:prefLabel" datatype="">PhpStorm</a></li></ul></section><ul class="links inline"><li class="service-links-delicious first"><a href="http://del.icio.us/post?url=http%3A//openahmed.com/blog/how-i-do-development-setup&amp;title=How%20I%20do%20the%20development%20setup" title="Bookmark this post on del.icio.us." class="service-links-delicious" rel="nofollow" target="_blank"><img typeof="foaf:Image" class="image-style-none" src="http://openahmed.com/sites/all/modules/contrib/service_links/images/delicious.png" alt="del.icio.us" /></a></li><li class="service-links-facebook"><a href="http://www.facebook.com/sharer.php?u=http%3A//openahmed.com/blog/how-i-do-development-setup&amp;t=How%20I%20do%20the%20development%20setup" title="Share on Facebook." class="service-links-facebook" rel="nofollow" target="_blank"><img typeof="foaf:Image" class="image-style-none" src="http://openahmed.com/sites/all/modules/contrib/service_links/images/facebook.png" alt="Facebook" /></a></li><li class="service-links-google"><a href="http://www.google.com/bookmarks/mark?op=add&amp;bkmk=http%3A//openahmed.com/blog/how-i-do-development-setup&amp;title=How%20I%20do%20the%20development%20setup" title="Bookmark this post on Google." class="service-links-google" rel="nofollow" target="_blank"><img typeof="foaf:Image" class="image-style-none" src="http://openahmed.com/sites/all/modules/contrib/service_links/images/google.png" alt="Google" /></a></li><li class="service-links-slashdot"><a href="http://slashdot.org/bookmark.pl?url=http%3A//openahmed.com/blog/how-i-do-development-setup&amp;title=How%20I%20do%20the%20development%20setup" title="Bookmark this post on SlashDot" class="service-links-slashdot" rel="nofollow" target="_blank"><img typeof="foaf:Image" class="image-style-none" src="http://openahmed.com/sites/all/modules/contrib/service_links/images/slashdot.png" alt="SlashDot" /></a></li><li class="service-links-twitter"><a href="http://twitter.com/share?url=http%3A//openahmed.com/node/14&amp;text=How%20I%20do%20the%20development%20setup" title="Share this on Twitter" class="service-links-twitter" rel="nofollow" target="_blank"><img typeof="foaf:Image" class="image-style-none" src="http://openahmed.com/sites/all/modules/contrib/service_links/images/twitter.png" alt="Twitter" /></a></li><li class="service-links-yahoo last"><a href="http://bookmarks.yahoo.com/myresults/bookmarklet?u=http%3A//openahmed.com/blog/how-i-do-development-setup&amp;t=How%20I%20do%20the%20development%20setup" title="Bookmark this post on Yahoo." class="service-links-yahoo" rel="nofollow" target="_blank"><img typeof="foaf:Image" class="image-style-none" src="http://openahmed.com/sites/all/modules/contrib/service_links/images/yahoo.png" alt="Yahoo" /></a></li></ul>Tue, 22 Sep 2015 13:06:43 +0000sharique14 at http://openahmed.comhttp://openahmed.com/blog/how-i-do-development-setup#commentsInstalling drush 7 in windowshttp://openahmed.com/blog/installing-drush-7-windows
<div class="field field-name-body field-type-text-with-summary field-label-hidden view-mode-rss"><div class="field-items"><div class="field-item even" property="content:encoded"><p>Drush team recently released rc1 for version 7 of Drush, in this release they added a nice batch script to install it on windows. For this you have download latest 7.x release from <a href="https://github.com/drush-ops/drush/releases" target="_blank">https://github.com/drush-ops/drush/releases</a>, extract zip in a partition other than OS partition (like D drive, I extracted it in D:\install\). Now start command prompt as administrator, for this search for cmd in start menu, on result list right click on cmd and choose "Run as Administrator". Now goto the extracted folder (D:\install\windrush in my case) and run setenv.bat file. It will add drush to system variables and registry. Now open new command prompt and run drush, you will see usual drush help message.</p>
</div></div></div><section class="field field-name-field-tags field-type-taxonomy-term-reference field-label-above view-mode-rss"><h2 class="field-label">Tags:&nbsp;</h2><ul class="field-items"><li class="field-item even"><a href="/tags/drupal" typeof="skos:Concept" property="rdfs:label skos:prefLabel" datatype="">Drupal</a></li><li class="field-item odd"><a href="/tags/drush" typeof="skos:Concept" property="rdfs:label skos:prefLabel" datatype="">Drush</a></li></ul></section><ul class="links inline"><li class="service-links-delicious first"><a href="http://del.icio.us/post?url=http%3A//openahmed.com/blog/installing-drush-7-windows&amp;title=Installing%20drush%207%20in%20windows" title="Bookmark this post on del.icio.us." class="service-links-delicious" rel="nofollow" target="_blank"><img typeof="foaf:Image" class="image-style-none" src="http://openahmed.com/sites/all/modules/contrib/service_links/images/delicious.png" alt="del.icio.us" /></a></li><li class="service-links-facebook"><a href="http://www.facebook.com/sharer.php?u=http%3A//openahmed.com/blog/installing-drush-7-windows&amp;t=Installing%20drush%207%20in%20windows" title="Share on Facebook." class="service-links-facebook" rel="nofollow" target="_blank"><img typeof="foaf:Image" class="image-style-none" src="http://openahmed.com/sites/all/modules/contrib/service_links/images/facebook.png" alt="Facebook" /></a></li><li class="service-links-google"><a href="http://www.google.com/bookmarks/mark?op=add&amp;bkmk=http%3A//openahmed.com/blog/installing-drush-7-windows&amp;title=Installing%20drush%207%20in%20windows" title="Bookmark this post on Google." class="service-links-google" rel="nofollow" target="_blank"><img typeof="foaf:Image" class="image-style-none" src="http://openahmed.com/sites/all/modules/contrib/service_links/images/google.png" alt="Google" /></a></li><li class="service-links-slashdot"><a href="http://slashdot.org/bookmark.pl?url=http%3A//openahmed.com/blog/installing-drush-7-windows&amp;title=Installing%20drush%207%20in%20windows" title="Bookmark this post on SlashDot" class="service-links-slashdot" rel="nofollow" target="_blank"><img typeof="foaf:Image" class="image-style-none" src="http://openahmed.com/sites/all/modules/contrib/service_links/images/slashdot.png" alt="SlashDot" /></a></li><li class="service-links-twitter"><a href="http://twitter.com/share?url=http%3A//openahmed.com/node/13&amp;text=Installing%20drush%207%20in%20windows" title="Share this on Twitter" class="service-links-twitter" rel="nofollow" target="_blank"><img typeof="foaf:Image" class="image-style-none" src="http://openahmed.com/sites/all/modules/contrib/service_links/images/twitter.png" alt="Twitter" /></a></li><li class="service-links-yahoo last"><a href="http://bookmarks.yahoo.com/myresults/bookmarklet?u=http%3A//openahmed.com/blog/installing-drush-7-windows&amp;t=Installing%20drush%207%20in%20windows" title="Bookmark this post on Yahoo." class="service-links-yahoo" rel="nofollow" target="_blank"><img typeof="foaf:Image" class="image-style-none" src="http://openahmed.com/sites/all/modules/contrib/service_links/images/yahoo.png" alt="Yahoo" /></a></li></ul>Wed, 08 Apr 2015 07:34:35 +0000sharique13 at http://openahmed.comhttp://openahmed.com/blog/installing-drush-7-windows#commentsDrush 7 installation scripthttp://openahmed.com/blog/drush-7-installation-script
<div class="field field-name-body field-type-text-with-summary field-label-hidden view-mode-rss"><div class="field-items"><div class="field-item even" property="content:encoded"><p>To work with Drupal 8, we need Drush 7, which is in alpha stage of development. So there no package available for distribution (like Ubuntu, OpenSuse). Installation of Drush 7 is not as simple Drush 6, if you not familiar with composer, you may find it difficult to install, so I've written a shell script, which can be used to install Drush 7. </p>
<script src="https://gist.github.com/sharique/f870613184713f7ed535.js"></script><p>
This script install drush 7 for normal user, you don't need root access to run it.</p>
</div></div></div><section class="field field-name-field-tags field-type-taxonomy-term-reference field-label-above view-mode-rss"><h2 class="field-label">Tags:&nbsp;</h2><ul class="field-items"><li class="field-item even"><a href="/tags/drupal" typeof="skos:Concept" property="rdfs:label skos:prefLabel" datatype="">Drupal</a></li></ul></section><ul class="links inline"><li class="service-links-delicious first"><a href="http://del.icio.us/post?url=http%3A//openahmed.com/blog/drush-7-installation-script&amp;title=Drush%207%20installation%20script" title="Bookmark this post on del.icio.us." class="service-links-delicious" rel="nofollow" target="_blank"><img typeof="foaf:Image" class="image-style-none" src="http://openahmed.com/sites/all/modules/contrib/service_links/images/delicious.png" alt="del.icio.us" /></a></li><li class="service-links-facebook"><a href="http://www.facebook.com/sharer.php?u=http%3A//openahmed.com/blog/drush-7-installation-script&amp;t=Drush%207%20installation%20script" title="Share on Facebook." class="service-links-facebook" rel="nofollow" target="_blank"><img typeof="foaf:Image" class="image-style-none" src="http://openahmed.com/sites/all/modules/contrib/service_links/images/facebook.png" alt="Facebook" /></a></li><li class="service-links-google"><a href="http://www.google.com/bookmarks/mark?op=add&amp;bkmk=http%3A//openahmed.com/blog/drush-7-installation-script&amp;title=Drush%207%20installation%20script" title="Bookmark this post on Google." class="service-links-google" rel="nofollow" target="_blank"><img typeof="foaf:Image" class="image-style-none" src="http://openahmed.com/sites/all/modules/contrib/service_links/images/google.png" alt="Google" /></a></li><li class="service-links-slashdot"><a href="http://slashdot.org/bookmark.pl?url=http%3A//openahmed.com/blog/drush-7-installation-script&amp;title=Drush%207%20installation%20script" title="Bookmark this post on SlashDot" class="service-links-slashdot" rel="nofollow" target="_blank"><img typeof="foaf:Image" class="image-style-none" src="http://openahmed.com/sites/all/modules/contrib/service_links/images/slashdot.png" alt="SlashDot" /></a></li><li class="service-links-twitter"><a href="http://twitter.com/share?url=http%3A//openahmed.com/node/11&amp;text=Drush%207%20installation%20script" title="Share this on Twitter" class="service-links-twitter" rel="nofollow" target="_blank"><img typeof="foaf:Image" class="image-style-none" src="http://openahmed.com/sites/all/modules/contrib/service_links/images/twitter.png" alt="Twitter" /></a></li><li class="service-links-yahoo last"><a href="http://bookmarks.yahoo.com/myresults/bookmarklet?u=http%3A//openahmed.com/blog/drush-7-installation-script&amp;t=Drush%207%20installation%20script" title="Bookmark this post on Yahoo." class="service-links-yahoo" rel="nofollow" target="_blank"><img typeof="foaf:Image" class="image-style-none" src="http://openahmed.com/sites/all/modules/contrib/service_links/images/yahoo.png" alt="Yahoo" /></a></li></ul>Fri, 19 Dec 2014 11:37:54 +0000sharique11 at http://openahmed.comhttp://openahmed.com/blog/drush-7-installation-script#commentsCreating a custom block in Drupal 8http://openahmed.com/blog/creating-custom-block-drupal-8
<div class="field field-name-body field-type-text-with-summary field-label-hidden view-mode-rss"><div class="field-items"><div class="field-item even" property="content:encoded"><p>Block is a very basic building block of any site. Blocks in drupal 8 are very different from what we are using in d7. In D8 blocks are plugins (like ctool content type plugin) and also entity. One more major improvement from site builder is that now you can have more than one instance of a block on same page, all instances can have different configuration, which was nightmare in d7. In d7 to achieve this you have to use either use panels or delta + context modules. Even in this way you can’t have different configuration for each instance. By creating mini panels you can have different configuration for each mini panel, which make page heavy and it will be slower to load. Now you can do this easily without using any contrib module.</p>
<p>Creating custom block using code is much easier in D8 as compared to D7. All that you have to do is create a class using BlockBase as base in “my_module/src/Plugin/Block” and implement at build function, which is for building block. If you look closely at the path, you will realize that you’re creating new Block type plugin.<br />
The code of for creating is as follows</p>
<pre class="brush: php">
namespace Drupal\test_testing\Plugin\Block;
use Drupal\block\BlockBase;
/**
* Provides a 'test empty block' block.
*
* @Block(
* id = "test_empty",
* subject = @Translation("test: empty block"),
* admin_label = @Translation("test: empty block")
* )
*/
class MyBlock extends BlockBase {
public function build() {
$config = $this-&gt;getConfiguration();
return array(
'#type'=&gt;'markup',
'#markup'=&gt;t('This is test block : '). $config['test_field1'],
'#title'=&gt;t('test block title'),
);
}
/**
* {@inheritdoc}
*/
public function blockForm($form, &amp;$form_state) {
$form = parent::blockForm($form, $form_state);
//Retrieve existing configuration for this block.
$config = $this-&gt;getConfiguration();
$form['test_field1']=array(
'#type'=&gt;'textfield',
'#title'=&gt;t('Block setting'),
'#default_value' =&gt; isset($config['test_field1']) ? $config['test_field1'] : '',
);
return $form;
}
}
</pre><p>
The first line tells the name space of the newly created block class. Second line is to include base class (BlockBase in case of block). </p>
<pre class="brush: php">
namespace Drupal\test_testing\Plugin\Block;
use Drupal\block\BlockBase;
</pre><p>
Next comes YAML annotation to describe the new block. At lease id is required here, if you do not provide the id, drupal will not be able recognize block correctly. </p>
<pre class="brush: php">
/**
* Provides a 'test empty block' block.
*
* @Block(
* id = "test_empty",
* subject = @Translation("test: empty block"),
* admin_label = @Translation("test: empty block")
* )
*/
</pre><p>Next comes the block class. I’ve implemented only 2 methods here, build and blockForm.</p>
<p>The build method is the heart of the block, it returns the markup of the block in array format.Method buildForm is for configuration form of the block. Here I’ve defined only one text field, value entered will be displayed on the block. I am doing this to show that each block instance will separate configuration. Method getConfiguration is used to retrieve the saved configuration of the block. Did you noticed that there is no form_submit, you don’t need to a submit method to save the configuration, if you are doing some processing than you need one. Method for submit is blockSubmit.</p>
<p>Note:- Drupal 8 is still in development, so api might change.</p>
</div></div></div><section class="field field-name-field-tags field-type-taxonomy-term-reference field-label-above view-mode-rss"><h2 class="field-label">Tags:&nbsp;</h2><ul class="field-items"><li class="field-item even"><a href="/tags/drupal" typeof="skos:Concept" property="rdfs:label skos:prefLabel" datatype="">Drupal</a></li></ul></section><ul class="links inline"><li class="service-links-delicious first"><a href="http://del.icio.us/post?url=http%3A//openahmed.com/blog/creating-custom-block-drupal-8&amp;title=Creating%20a%20custom%20block%20in%20Drupal%208" title="Bookmark this post on del.icio.us." class="service-links-delicious" rel="nofollow" target="_blank"><img typeof="foaf:Image" class="image-style-none" src="http://openahmed.com/sites/all/modules/contrib/service_links/images/delicious.png" alt="del.icio.us" /></a></li><li class="service-links-facebook"><a href="http://www.facebook.com/sharer.php?u=http%3A//openahmed.com/blog/creating-custom-block-drupal-8&amp;t=Creating%20a%20custom%20block%20in%20Drupal%208" title="Share on Facebook." class="service-links-facebook" rel="nofollow" target="_blank"><img typeof="foaf:Image" class="image-style-none" src="http://openahmed.com/sites/all/modules/contrib/service_links/images/facebook.png" alt="Facebook" /></a></li><li class="service-links-google"><a href="http://www.google.com/bookmarks/mark?op=add&amp;bkmk=http%3A//openahmed.com/blog/creating-custom-block-drupal-8&amp;title=Creating%20a%20custom%20block%20in%20Drupal%208" title="Bookmark this post on Google." class="service-links-google" rel="nofollow" target="_blank"><img typeof="foaf:Image" class="image-style-none" src="http://openahmed.com/sites/all/modules/contrib/service_links/images/google.png" alt="Google" /></a></li><li class="service-links-slashdot"><a href="http://slashdot.org/bookmark.pl?url=http%3A//openahmed.com/blog/creating-custom-block-drupal-8&amp;title=Creating%20a%20custom%20block%20in%20Drupal%208" title="Bookmark this post on SlashDot" class="service-links-slashdot" rel="nofollow" target="_blank"><img typeof="foaf:Image" class="image-style-none" src="http://openahmed.com/sites/all/modules/contrib/service_links/images/slashdot.png" alt="SlashDot" /></a></li><li class="service-links-twitter"><a href="http://twitter.com/share?url=http%3A//openahmed.com/node/9&amp;text=Creating%20a%20custom%20block%20in%20Drupal%208" title="Share this on Twitter" class="service-links-twitter" rel="nofollow" target="_blank"><img typeof="foaf:Image" class="image-style-none" src="http://openahmed.com/sites/all/modules/contrib/service_links/images/twitter.png" alt="Twitter" /></a></li><li class="service-links-yahoo last"><a href="http://bookmarks.yahoo.com/myresults/bookmarklet?u=http%3A//openahmed.com/blog/creating-custom-block-drupal-8&amp;t=Creating%20a%20custom%20block%20in%20Drupal%208" title="Bookmark this post on Yahoo." class="service-links-yahoo" rel="nofollow" target="_blank"><img typeof="foaf:Image" class="image-style-none" src="http://openahmed.com/sites/all/modules/contrib/service_links/images/yahoo.png" alt="Yahoo" /></a></li></ul>Mon, 09 Jun 2014 14:21:55 +0000sharique9 at http://openahmed.comhttp://openahmed.com/blog/creating-custom-block-drupal-8#comments