Skip to content

Commit

Permalink
categories and post image working
Browse files Browse the repository at this point in the history
  • Loading branch information
sujaykundu777 committed Jul 4, 2018
1 parent c021edf commit 36c2e9c
Show file tree
Hide file tree
Showing 36 changed files with 259 additions and 54 deletions.
109 changes: 103 additions & 6 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -56,18 +56,115 @@ The theme is available as open source under the terms of the [MIT License](https

`{{site.variable}}`

title, description, name , bio
# _config.yml configuration ( Copy and Edit accordingly )

twitter_username, facebook_username, medium_username , telegram_username, behance_username, github_username ,
instagram_username
```
title: Your Site Title
subtitle: Your Site Subtitle
description: >- # this means to ignore newlines until "baseurl:"
Write an awesome description for your new site here. You can edit this
line in _config.yml. It will appear in your document head meta (for
Google search results) and in your feed.xml site description.
baseurl: "" # the subpath of your site, e.g. /blog
url: "" # the base hostname & protocol for your site, e.g. http://example.com

author_logo: profile.png
disqus_shortname: sujay-kundu #for comments using disqus
author: Your Name
author_bio: Something About You for about me
author_email: "[email protected]"
author_location: Your Location
author_website_url: "https://yourwebsite.com"

# social links
twitter_username: yourusername
github_username: yourusername
facebook_username: yourusername
linkedin_username: yourusername
behance_username: yourusername
instagram_username: yourusername
medium_username: yourusername
telegram_username: yourusername
dribbble_username: yourusername
flickr_username: yourusername
```
# Add blog section
Create a new file blog.md file with following content
Create a new file blog.md file with following front yaml inside it.
```
---
layout: blog
title: Blog
permalink: \blog\
```
permalink: \blog\
---
```
# Post Yaml Format ( Example Below ) :
```
---
layout: post
title: How to use docker compose
categories:
- web-development
- docker
summary: Learn how to use docker compose
thumbnail: docker-compose.png
author: Sujay Kundu
---
```
# Adding Categories
For Adding Categories create new folder categories and inside that create a file `all.md` and copy the below code in that :
```
---
layout: page
permalink: /blog/categories/
---

<div id="categories">
{% for tag in site.categories %}
<div class="category-box" >
{% capture tag_name %}{{ tag | first }}{% endcapture %}
<div id="#{{ tag_name | slugize }}"></div>
<h4 class="tag-head"><a href="{{ site.baseurl }}/blog/categories/{{ tag_name }}">{{ tag_name }}</a></h4>
<a name="{{ tag_name | slugize }}"></a>
{% for post in site.tags[tag_name] %}
<article class="center">
<h6 ><a href="{{ site.baseurl }}{{ post.url }}">{{post.title}}</a></h6>
</article>


{% endfor %}

</div>
{% endfor %}
</div>

```
# Individual Categories
If you want to show all posts of a particular category, create a new file for that category inside categories folder
For example ( angularjs.md )
```
---
layout: page
permalink: /blog/categories/angularjs
---

<div class="card">
{% for post in site.categories.angularjs %}
<li class="category-posts"><span>{{ post.date | date_to_string }}</span> &nbsp; <a href="{{ post.url }}">{{ post.title }}</a></li>
{% endfor %}
</div>


```
78 changes: 31 additions & 47 deletions _layouts/post.html
Original file line number Diff line number Diff line change
Expand Up @@ -3,15 +3,15 @@
---

<nav aria-label="breadcrumb" role="navigation">
<ol class="breadcrumb">
<li class="breadcrumb-item">
<a href="/blog">Blog</a>
</li>
<li class="breadcrumb-item">
<a href="/blog/categories">Categories</a>
</li>
<li class="breadcrumb-item active" aria-current="page">{{ page.title }}</li>
</ol>
<ol class="breadcrumb">
<li class="breadcrumb-item">
<a href="/blog">Blog</a>
</li>
<li class="breadcrumb-item">
<a href="/blog/categories">Categories</a>
</li>
<li class="breadcrumb-item active" aria-current="page">{{ page.title }}</li>
</ol>
</nav>

<div class="row">
Expand Down Expand Up @@ -46,7 +46,7 @@ <h4 class="post-meta">{{ page.summary }}</h4>
</div>

<div class="card-body" itemprop="articleBody">
<img class="card-img-top" src="{{site.url}}/assets/img/{{ post.thumbnail }}" alt="{{ post.title }}"> {{ content }} {%- include share.html -%}
<img class="card-img-top" src="{{site.url}}/assets/img/{{ page.thumbnail }}" alt="{{ post.title }}"> {{ content }} {%- include share.html -%}
</div>

<div id="disqus_thread"></div>
Expand Down Expand Up @@ -75,44 +75,28 @@ <h4 class="post-meta">{{ page.summary }}</h4>
</div>
<div class="card">
<!-- Begin MailChimp Signup Form -->
<div id="mc_embed_signup">
<form action="https://programmingebooks.us10.list-manage.com/subscribe/post?u=50bab1c85eae24ecfb0f68361&amp;id=3a2dd721d0"
method="post" id="mc-embedded-subscribe-form" name="mc-embedded-subscribe-form" class="validate" target="_blank"
novalidate>
<div id="mc_embed_signup_scroll">
<label for="mce-EMAIL">Subscribe via Email :</label>
<input type="email" value="" name="EMAIL" class="email" id="mce-EMAIL" placeholder="email address" required>
<!-- real people should not fill this in and expect good things - do not remove this or risk form bot signups-->
<div style="position: absolute; left: -5000px;" aria-hidden="true">
<input type="text" name="b_50bab1c85eae24ecfb0f68361_3a2dd721d0" tabindex="-1" value="">
</div>
<div class="clear">
<input type="submit" value="Subscribe" name="subscribe" id="mc-embedded-subscribe" class="btn btn-md btn-default">
</div>
</div>
</form>
</div>
{%- include newsletter.html -%}
</div>
</div>
<!-- End of Sidebar -->

</div>

<script>
var disqus_config = function () {
this.page.url = "{{ site.url }}{{ page.url }}"; // Replace PAGE_URL with your page's canonical URL variable
this.page.identifier = "{{ page.id }}"; // Replace PAGE_IDENTIFIER with your page's unique identifier variable
};


(function () { // DON'T EDIT BELOW THIS LINE
var d = document,
s = d.createElement('script');
s.src = 'https://{{ site.disqus_shortname }}.disqus.com/embed.js';
s.setAttribute('data-timestamp', +new Date());
(d.head || d.body).appendChild(s);
})();
</script>
<noscript>Please enable JavaScript to view the
<a href="https://disqus.com/?ref_noscript">comments powered by Disqus.</a>
</noscript>
</div>

<script>
var disqus_config = function () {
this.page.url = "{{ site.url }}{{ page.url }}"; // Replace PAGE_URL with your page's canonical URL variable
this.page.identifier = "{{ page.id }}"; // Replace PAGE_IDENTIFIER with your page's unique identifier variable
};


(function () { // DON'T EDIT BELOW THIS LINE
var d = document,
s = d.createElement('script');
s.src = 'https://{{ site.disqus_shortname }}.disqus.com/embed.js';
s.setAttribute('data-timestamp', +new Date());
(d.head || d.body).appendChild(s);
})();
</script>
<noscript>Please enable JavaScript to view the
<a href="https://disqus.com/?ref_noscript">comments powered by Disqus.</a>
</noscript>
60 changes: 60 additions & 0 deletions _posts/2017-11-23-using-git-like-pro.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,60 @@
---
title: Using Git Like Pro
layout: post
summary: Learn how to use all git commands
categories:
- git
- web-development
thumbnail: gitflow-workflow.png
author: Sujay Kundu
---

# Useful git commands

Remove a remote origin for the project

```
$ git remote -v
```

View current remotes

```
origin https://github.com/OWNER/REPOSITORY.git (fetch)
origin https://github.com/OWNER/REPOSITORY.git (push)
destination https://github.com/FORKER/REPOSITORY.git (fetch)
destination https://github.com/FORKER/REPOSITORY.git (push)
```

```
$ git remote rm origin
```

`$ git remote rm destination`

Add a remote origin for the project

`$ git remote add origin https://github.com/OWNER/REPOSITORY.git`

Check current remotes

```
origin https://github.com/OWNER/REPOSITORY.git (fetch)
origin https://github.com/OWNER/REPOSITORY.git (push)
```


Push a new local branch to a remote Git repository and track it too

Create a new branch:
```
git checkout -b feature_branch_name
```

Edit, add and commit your files.

Push your branch to the remote repository:

```
git push -u origin feature_branch_name
```
Binary file added assets/img/android-chrome-192x192.png
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 assets/img/android-chrome-512x512.png
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 assets/img/apple-touch-icon.png
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 assets/img/favicon-16x16.png
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 assets/img/favicon-32x32.png
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 assets/img/favicon.ico
Binary file not shown.
Binary file added assets/img/gitflow-workflow.png
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 assets/img/mstile-150x150.png
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 assets/img/projects/CBSHOYEUkAAxfSm.png_large
Binary file not shown.
Binary file added assets/img/projects/Music.png
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 assets/img/projects/alex.png
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 assets/img/projects/amigosevents.png
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 assets/img/projects/blogmapia.png
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 assets/img/projects/devlopr.png
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 assets/img/projects/foobar-1.png
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 assets/img/projects/foobar.png
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 assets/img/projects/frutzi.png
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 assets/img/projects/gamershub.png
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 assets/img/projects/hackify.png
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 assets/img/projects/klj.png
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 assets/img/projects/musifier.png
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 assets/img/projects/peb.png
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 assets/img/projects/programmingebooks_frnt.png
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 assets/img/projects/react-router.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
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 assets/img/projects/screenshotmy.png
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 assets/img/projects/snap2.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 assets/img/projects/snap3.jpg
28 changes: 28 additions & 0 deletions categories/all.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,28 @@
---
layout: page
permalink: /blog/categories/
---


<h3> {{ page.title }} </h3>

<div id="categories">
{% for tag in site.categories %}
<div class="category-box" >
{% capture tag_name %}{{ tag | first }}{% endcapture %}
<div id="#{{ tag_name | slugize }}"></div>
<h4 class="tag-head"><a href="{{ site.baseurl }}/blog/categories/{{ tag_name }}">{{ tag_name }}</a></h4>
<a name="{{ tag_name | slugize }}"></a>
{% for post in site.tags[tag_name] %}
<article class="center">
<h6 ><a href="{{ site.baseurl }}{{ post.url }}">{{post.title}}</a></h6>
</article>


{% endfor %}

</div>
{% endfor %}
</div>


12 changes: 12 additions & 0 deletions categories/git.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,12 @@
---
layout: page
permalink: /blog/categories/git
---

<h3> Posts by Category : {{ page.title }} </h3>

<div class="card">
{% for post in site.categories.git %}
<li class="category-posts"><span>{{ post.date | date_to_string }}</span> &nbsp; <a href="{{ post.url }}">{{ post.title }}</a></li>
{% endfor %}
</div>
12 changes: 12 additions & 0 deletions categories/jekyll.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,12 @@
---
layout: page
permalink: /blog/categories/jekyll
---

<h3> Posts by Category : {{ page.title }} </h3>

<div class="card">
{% for post in site.categories.jekyll %}
<li class="category-posts"><span>{{ post.date | date_to_string }}</span> &nbsp; <a href="{{ post.url }}">{{ post.title }}</a></li>
{% endfor %}
</div>
12 changes: 12 additions & 0 deletions categories/web-development.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,12 @@
---
layout: page
permalink: /blog/categories/web-development
---

<h3> Posts by Category : {{ page.title }} </h3>

<div class="card">
{% for post in site.categories.web-development %}
<li class="category-posts"><span>{{ post.date | date_to_string }}</span> &nbsp; <a href="{{ post.url }}">{{ post.title }}</a></li>
{% endfor %}
</div>
2 changes: 1 addition & 1 deletion devlopr.gemspec
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@

Gem::Specification.new do |spec|
spec.name = "devlopr"
spec.version = "0.1.9"
spec.version = "0.2.0"
spec.authors = ["Sujay Kundu"]
spec.email = ["[email protected]"]

Expand Down

0 comments on commit 36c2e9c

Please sign in to comment.