Code Monkey home page Code Monkey logo

fast_template's Introduction

Your blog

This is the repository for your blog! Click _config.yml above to get started and fill in the details. Then click index.md and edit it to start creating your home page.

fast_template's People

Contributors

hamelsmu avatar jph00 avatar natikgadzhi avatar

Stargazers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

Watchers

 avatar  avatar  avatar  avatar  avatar

fast_template's Issues

Support for Google Analytics 4

In Google Analytics 4 there is no tracking id (UA-XXXXXX-X) rather we have Measurement ID. When we use it inf _config.yml it doesn't track data. According to this issue (jekyll/minima#561), it's jekyll issue. Three is a mention of a solution here,

# _config.yml

- theme: minima
+ remote_theme: jekyll/minima

  plugins:
+ - jekyll-remote-theme

But if we try it we get a build error in assets/main.scss with the following msg,

      Layout source: theme
         Rendering: assets/main.scss
  Pre-Render Hooks: assets/main.scss
  Rendering Liquid: assets/main.scss
  Rendering Markup: assets/main.scss
github-pages 227 | Error:  File to import not found or unreadable: minima.
Load paths:
  /usr/local/bundle/gems/jekyll-theme-primer-0.6.0/_sass
  /tmp/jekyll-remote-theme-20220715-10-15anlab/_sass on line 1
      Remote Theme: Cleaning up /tmp/jekyll-remote-theme-20220715-10-15anlab

Add home.html and footer.html from original minima

I really like the idea but with the current version, it is not possible to edit the footer nor to remove the RSS link.

I had to look in the original minima repository and copy the files for my version.

Social Media: G+ has closed

{%- if site.googleplus_username -%}<li><a href="https://plus.google.com/{{ site.googleplus_username| escape }}"><svg class="svg-icon"><use xlink:href="{{ '/assets/minima-social-icons.svg#googleplus' | relative_url }}"></use></svg> <span class="username">{{ site.googleplus_username| escape }}</span></a></li>{%- endif -%}

https://en.wikipedia.org/wiki/Google%2B, discontinued since April 2019. Should it remain in the template?

Adding Automated Tests

I would love to add automated tests to ensure that the conversion pipeline happens properly, but I need a place to put dummy notebooks and word docs. Let me know if you have suggestions, I know we wanted to leave these files out of the repo initially to avoid confusion.

Let me know if you have any suggestions on this and I will write the tests, this is what I have in mind for the tests:

  • test that notebooks/word docs can be converted to .md without error
  • test that the Jekyll build happens without error (I could use the same version of Jekyll as GitHub pages)

Bug in converting to MD step in tutorial

I have followed the steps on the page https://www.fast.ai/2020/01/16/fast_template/, where you detail how to set up a blog etc. I've encountered what seems to be a bug - when using the command nbdev_nb2md test.ipynb the notebook itself is being modified. Specifically, any image markdown links do not work after the nbdev conversion process. I checked the notebook before running it and after, and can see that the attachments field has been removed during the conversion. Nothing else seems to have changed, so should be an easy fix if it is actually a bug?

If it is intentional tho, please could you consider this a feature request for the original notebook not to be changed when converting?

Issue With Automatic nb & word conversion

@jph00 I found a serious issue with the notebook and word to blog conversion that I didn't notice before.

It turns out that a GitHub Action is also responsible behind the scenes for building your GitHub pages. As a security measure, an event triggered by one GitHub Action cannot trigger another GitHub Action.

This means something other than an Action has to make a commit to the repo to force a fresh page build. This means that after the automated system converts your files for you, you have to make some kind of change in your repo for the build to start.

I have no idea why I did not notice this before, and I am not sure if this is the result of a recent change ( but I couldn't find anything saying it was a recent change ).

The only remedy to this situation is to supply a secret in Actions with a personal access token which can authenticate as a user to make the last commit into the repo. I'm going to formulate a PR for this soon, just wanted to open an issue and let you know about this ASAP

$||.||$ in math mode becomes a table

I am using use_math: true. Most of the equations are visible as expected, however, equations involving norms (||.||) are being converted to tables. I am using the $.$ sign for equations to make sure that the latex is being converted.

A sample is shown below:
Text: If no solution exists then it gives $x$ such that $Ax$ is as close to $b$ as possible in terms of $||b-Ax||_2$
Output in Blog:

image

Social icons overlapping with text

So I tried to set up my blog and i got this ugly overlapping social icons.

Screenshot from 2020-02-16 13-29-19

I think only a little more width will fix this issue. Like Karpathy's blog

Screenshot from 2020-02-16 13-29-32

Add Google analytics

When a google analytics ID is specified in _config.yml, eg:

google_analytics: UA-NNNNNNNN-N

Then the generated website is tracked using google analytics.

Image attachment with private repositories

Hi! Sometimes in my posts I tend to have sensitive API keys and so I use a private repository for hosting the blog. In using a private repository, the images become inaccessible via direct link and are not able to be attached into a post using syntax like ![Image of fast.ai logo](images/logo.png). Do you have any suggestions on this?

How to Convert MS Word Equation into Markdown LaTex Equation

Thanks for the amazing work that make blogging so easy.

I am trying to make my first (testing) post with Microsoft Word. The attached is what I wrote in the Word file:

equ

But I found that pandoc didn't convert it to Markdown LaTex equation. The attached is what is shown in the blog:

equ2

Just wonder if there is a solution/ walkaround for this?

How to upgrade?

Hi Jeremy,

Thank you so much for this project. It made blogging really easy.

I have already set up a blog yesterday and just found a new feature you posted on twitter (the auto conversion of word docs). I would like to have a try. Do I need to repeat the whole procedure to reset a new blog? Or can I get the template upgraded directly with a command?

Looking forward to your reply. Thanks!

Adding Disqus with as comment section causes post to lost

I have such Github pages - https://github.com/Diyago/Diyago.github.io

To add comments section, I created post.html with disqus code sniptset under __layout folder:

<div id="disqus_thread"></div>
<script>

/**
*  RECOMMENDED CONFIGURATION VARIABLES: EDIT AND UNCOMMENT THE SECTION BELOW TO INSERT DYNAMIC VALUES FROM YOUR PLATFORM OR CMS.
*  LEARN WHY DEFINING THESE VARIABLES IS IMPORTANT: https://disqus.com/admin/universalcode/#configuration-variables*/
/*
var disqus_config = function () {
this.page.url = PAGE_URL;  // Replace PAGE_URL with your page's canonical URL variable
this.page.identifier = PAGE_IDENTIFIER; // 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://https-diyago-github-io.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>

It actually works but all information disappears from post.html, I need to change it somehow, but how?

help needed changing themes

template worked great but when I edited _config.yml to switch to the jekyll-theme-hacker theme, I lost the list of posts ..
any chance of some hints about changing themes?
thanks

Embed image with url in notebook

When the notebook to be published containts a url to the internet, the convertion of the notebook to a post gives an error.

I tried three options:

  1. Embed using markup
![Example Bullet Chart](https://jscharting.com/blog/bullet-charts/images/bullet_components.png)
  1. Embed using Image
from IPython.display import Image
Image('https://jscharting.com/blog/bullet-charts/images/bullet_components.png')
  1. Embed as HTML
<img src="https://jscharting.com/blog/bullet-charts/images/bullet_components.png" alt="Bullet chart" style="width: 200px;"/>

In case 3, this is the error in (https://github.com/cast42/cast42.github.io/runs/415599290?check_suite_focus=true):

converting: _notebooks/2020_01_29_bullet_chart_altair.ipynb
[Errno 2] No such file or directory: '/home/runner/work/cast42.github.io/cast42.github.io/_notebooks/https:/jscharting.com/blog/bullet-charts/images/bullet_components.png'
converting: _notebooks/2020-01-28-Altair.ipynb
Traceback (most recent call last):
  File "_action_files/nb2post.py", line 23, in <module>
    export2html.notebook2html(fname='_notebooks/*.ipynb', dest='_posts/')
  File "/home/runner/work/cast42.github.io/cast42.github.io/nbdev/nbdev/export2html.py", line 410, in notebook2html
    raise Exception(msg + '\n'.join([f.name for p,f in zip(passed,files) if not p]))
  File "/home/runner/work/cast42.github.io/cast42.github.io/nbdev/nbdev/export2html.py", line 410, in <listcomp>
    raise Exception(msg + '\n'.join([f.name for p,f in zip(passed,files) if not p]))
AttributeError: 'str' object has no attribute 'name'
##[error]Process completed with exit code 1.

Discussion: Ideas to mitigate sync issues for users when using /_notebooks or /_word

The way the automation for _word and _notebooks work are the new files are pushed onto the master branch after the user pushes, which causes their local branch to get out of sync. This understandably causes confusion. For example, see this tweet

image

I have an idea on how to mitigate this. I could have GitHub Actions always keep the gh-pages branch updated automatically. This would require pushing to gh-pages after each push or build. This would require the following changes in the docs:

  • We would have to add an additional step in the setup process where the user selects the gh-pages option.
  • Add some clarification in the docs on how this all works, for example a warning not to edit the gh-pages branch directly since that will get overwritten.
  • We could probably remove the /sync magic command from the commit messages as well for /_notebooks since this may no longer be needed.

Thoughts? Is this a crazy idea? This is assuming that people are working in their master branch or another branch and can safely ignore the gh-pages branch.

Removing borders from images

Hello,

How do I remove the borders from images?

I wrote a blog post regarding matrices and uploaded the matrices as images. The matrices have borders around them, that I would like to remove, is there any setting I can use? link to blog is here

When applying additional themes , it loses the list of post from homepage

I was trying to apply additional themes provided by github pages , but that results in loss of the
posts from homepage.

Is there a way to add hyperlinks to all the posts when using another theme.

Note : I have little or no knowledge about Ruby , was trying to fix it on my own but need help here.

How to display math equations?

I typed the Stirling's approximation in LaTeX: $n! \approx \sqrt(2 \pi) n^{n+0.5} / \e^{n}$.
But the readable math equation was not displayed in my blog.
How to fix this please?

btw, the very short equations, eg, $n$ works fine.

Add post preview in the home page

Hi! I have generated a blog which can be visited at

https://davidefiocco.github.io/

What I ideally would like to add is a small paragraph under each post title as tl;dr/short snippet to briefly describe each of the blogposts. Currently just the titles make it to the home:

image

Is this easy to achieve?

Thanks for the template, @fastai!

possible pandoc issues to be aware of

issue: Pandoc seems to have a problem with ampersands translated as /amp&

workaround: don't use ampersands

issue: image missing from the rendered page in the browser. Again this seems to be a pandoc issue

workaround: insert jpegs/pngs/gifs etc. from a saved file in a folder rather than cut and pasting from browser into word doc

How to attach local images?

I have been facing a problem attaching locally present images in my blogs. I can't seem to understand the directory referencing which works here. Can someone clear this for me?

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.