diff --git a/.github/workflows/jekyll.yml b/.github/workflows/jekyll.yml deleted file mode 100644 index 1f74904..0000000 --- a/.github/workflows/jekyll.yml +++ /dev/null @@ -1,37 +0,0 @@ -name: Jekyll site CI - -on: - push: - branches: [ master ] - pull_request: - branches: [ master ] - -jobs: - build_and_deploy: - runs-on: ubuntu-latest - steps: - - name: GitHub Checkout - uses: actions/checkout@v1 - - name: Bundler Cache - uses: actions/cache@v1 - with: - path: vendor/bundle - key: ${{ runner.os }}-gems-${{ hashFiles('**/Gemfile.lock') }} - restore-keys: | - ${{ runner.os }}-gems- - - name: Build & Deploy to GitHub Pages - uses: joshlarsen/jekyll4-deploy-gh-pages@master - env: - GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }} - GITHUB_REPOSITORY: ${{ secrets.GITHUB_REPOSITORY }} - GITHUB_ACTOR: ${{ secrets.GITHUB_ACTOR }} - - name: Rsync the build - uses: Pendect/action-rsyncer@v1.1.0 - env: - DEPLOY_KEY: ${{secrets.DEPLOY_KEY}} - with: - src: _site/ - # Remote server and path. i.e user@server.com:/var/www/server.com/ - dest: nnieto@opal3.opalstack.com:/home/nnieto/apps/blog_noenieto_com/ - - name: Display status from deploy - run: echo "${{ steps.deploy.outputs.status }}" diff --git a/Gemfile b/Gemfile index ca0fe2d..3472df5 100644 --- a/Gemfile +++ b/Gemfile @@ -11,4 +11,7 @@ group :jekyll_plugins do gem 'jekyll-remote-theme' gem 'jekyll-paginate' gem 'jekyll-timeago' + gem 'jekyll-thumbnail-img' + gem 'bulma-clean-theme', '~> 1.0', '>= 1.0.2' + gem 'jekyll-toc' end diff --git a/_config.yml b/_config.yml index 02b0b0a..4d77603 100644 --- a/_config.yml +++ b/_config.yml @@ -1,9 +1,10 @@ plugins: - jekyll-feed - - jekyll-remote-theme - jekyll-seo-tag - jekyll-sitemap - jekyll-timeago + - jekyll-thumbnail-img + - jekyll-toc title: Noe Nieto tagline: Mi sitio personal | Personal site email: nnieto@noenieto.com @@ -33,7 +34,8 @@ webmaster_verifications: yandex: 1234 baidu: 1234 facebook: 1234 -remote_theme: chrisrhymes/bulma-clean-theme@v1.0.0 +# remote_theme: chrisrhymes/bulma-clean-theme@v1.0.0 +theme: bulma-clean-theme google_analytics: UA-34700214-1 # Disqus diff --git a/_includes/thumbnail_modal.html b/_includes/thumbnail_modal.html new file mode 100644 index 0000000..4422ed4 --- /dev/null +++ b/_includes/thumbnail_modal.html @@ -0,0 +1,2 @@ +{% capture thumb %}{% thumbnail_img include.img 48 %}{% endcapture %} +{% include image-modal.html ratio="is-48x48" link=thumb alt="Example image" large_link=include.img %} diff --git a/_plugins/site_stats.rb b/_plugins/site_stats.rb new file mode 100644 index 0000000..e4b2e5a --- /dev/null +++ b/_plugins/site_stats.rb @@ -0,0 +1,38 @@ +Jekyll::Hooks.register :site, :post_read do |site| + # Define the directories to search for images + image_directories = ['assets/images', 'images', '_posts'] + + # Initialize the image count + image_count = 0 + + # Supported image extensions + image_extensions = ['.jpg', '.jpeg', '.png', '.gif', '.bmp', '.svg', '.webp'] + + # Iterate through the specified directories + image_directories.each do |dir| + Dir.glob(File.join(site.source, dir, '**', '*')) do |file| + if image_extensions.include?(File.extname(file).downcase) + image_count += 1 + end + end + end + + # Initialize the draft count + draft_count = 0 + + # Path to the _drafts directory + drafts_dir = File.join(site.source, '_drafts') + + # Check if the _drafts directory exists + if Dir.exist?(drafts_dir) + # Count the number of markdown files in the _drafts directory + draft_count = Dir.glob(File.join(drafts_dir, '**', '*.{md,markdown}')).size + end + + site.config['stats'] = { + 'posts' => site.posts.size, + 'drafts' => draft_count, + 'pages' => site.pages.size, + 'Images' => image_count + } +end diff --git a/about.md b/about.md index d256c50..8ba743f 100644 --- a/about.md +++ b/about.md @@ -21,14 +21,82 @@ Aren't we cute? We love dogs. But there's a running joke about their names: Except for *Pulga* (flea in spanish), they are happily named after sweets and candies. For the sake of clarity Here's a table of their names, an english translation and an illustration of each sweet. -Name | Gender | Age | English translation (if available) | Sweet example | Dog photo -------------| ------ | --- | ---------------------------------- | --------------| --------- -Bombon | F | 9 | Marshmallow | ![We call her bombon becuse her white fur]({{"/media/bombonas//bombon1.png" | absolute_url}} "This is a marshmallow") | bar -Chocorol | M | 5 | | foo | bar -Candy | F | 4 | Candy | foo | bar -Winnis | F | 3 | | foo | bar -Tutsi | F | 3 | | foo | bar -Cookies | F | 3 | Cookies | foo | bar -Bubulubu | F | 3 | | foo | bar -Pulga | F | 2 | Flea | foo | bar +
Name | +Gender | +Age | +English translation (if available) | +Sweet example | +Dog photo | +
---|---|---|---|---|---|
Bombon | +F | +{{ site.time | date: '%y' | plus: -14 }} | +Marshmallow. A.K.A. Bombota, Bombotita, Bombosa, Bombonota | +{% include thumbnail_modal.html img='/media/bombonas/bombon1.png' %} | +bar | +
Chocorol | +M | +{{ site.time | date: '%y' | plus: -19 }} | +A popular chocolate cake roll (or Swiss Roll) available almost anywhere on Mexico. I also call him Don Checho | +{% include thumbnail_modal.html img='/media/bombonas/chocorol.webp' %} | +yay | +
Candy | +F | +{{ site.time | date: '%y' | plus: -20 }} | +A candy of the hard type. We also call her by Mamachita | +{% include thumbnail_modal.html img='/media/bombonas/candy.jpg' %} | +bar | +
Winnis | +F | +{{ site.time | date: '%y' | plus: -21 }} | +A popular soft candy in the Mexican border | +{% include thumbnail_modal.html img='/media/bombonas/winnis.webp' %} | +bar | +
Tutsi | +F | +{{ site.time | date: '%y' | plus: -21 }} | +The mexican version of the Cherry Tootsie lolipop. | +{% include thumbnail_modal.html img='/media/bombonas/tutsi.png' %} | +bar | +
Cookies | +F | +{{ site.time | date: '%y' | plus: -21 }} | +Cookies are delicious. We also call her Cuquis or Cuca | +{% include thumbnail_modal.html img='/media/bombonas/cookies.jpg' %} | +bar | +
Bubulubu | +F | +{{ site.time | date: '%y' | plus: -21 }} | +Bubulubu is another popular mexican sweet. It's a marshmallow/jellybean sandwich covered with chocolate. We also call her Buba | +{% include thumbnail_modal.html img='/media/bombonas/bubulubu.png' %} | +bar | +
Pulga | +F | +{{ site.time | date: '%y' | plus: -22 }} | +Flea. She's a tiny Chihuahua. We named her in honor of Bombona's mother: Pulga 1. | ++ | bar | +