Skip to content

Instantly share code, notes, and snippets.

View rusty-snake's full-sized avatar
🔮

rusty-snake

🔮
View GitHub Profile
@rusty-snake
rusty-snake / prompt.py
Last active July 2, 2019 09:39
The difference between a system language and a scripting language.
#!/usr/bin/env python3
# MIT License
#
# Copyright (c) 2019 rusty-snake (https://github.com/rusty-snake) <print_hello_world+License@protonmail.com>
#
# Permission is hereby granted, free of charge, to any person obtaining a copy
# of this software and associated documentation files (the "Software"), to deal
# in the Software without restriction, including without limitation the rights
# to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
@rusty-snake
rusty-snake / Headless_R-Pi_setup.md
Created December 19, 2018 18:36
How to set up a headless Raspberry Pi with Raspbian under Linux.

How to set up a headless Raspberry Pi with Raspbian under Linux.

This is a short descrieption for setup a headless (without Monitor/Display) Raspberry Pi with Raspbian under Linux using the shell.

  • First download a raspbian image from here and verify the sha256sum.
  • Secondly write the image to an microSD-Card. unzip RASPBIAN_IMAGE | sudo dd of=/dev/mmcblk0 bs=4M conf=fsync status=progress.
    • Replace RASPBIAN_IMAGE with the image that you downloaded before.
    • Replace /dev/mmcblk0 with your device name.
    • bs=4M make it faster, but maybe it causes problems, if it does, skip it.
  • conf=fsync can also causes problems, if you skip it, don't forget to run sudo sync after the command has finished.
@rusty-snake
rusty-snake / orage-bell.zsh
Created December 16, 2018 12:17
orage-bell - a script to display reminders.
#!/usr/bin/zsh
# MIT License
#
# Copyright (c) 2018 rusty-snake (https://github.com/rusty-snake) <print_hello_world+License@protonmail.com>
#
# Permission is hereby granted, free of charge, to any person obtaining a copy
# of this software and associated documentation files (the "Software"), to deal
# in the Software without restriction, including without limitation the rights
# to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
@rusty-snake
rusty-snake / chess_8_queens.py
Last active July 2, 2019 09:44
python script to solve the Eight queens puzzle
#!/usr/bin/env python3
# MIT License
#
# Copyright (c) 2018 rusty-snake (https://github.com/rusty-snake) <print_hello_world+License@protonmail.com>
#
# Permission is hereby granted, free of charge, to any person obtaining a copy
# of this software and associated documentation files (the "Software"), to deal
# in the Software without restriction, including without limitation the rights
# to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
@rusty-snake
rusty-snake / watchout.py
Last active July 2, 2019 09:39
ev3dev: python3-ev3dev2: A pogramm to avoid barriers.
#!/usr/bin/env python3
#
# MIT License
#
# Copyright (c) 2018 rusty-snake (https://github.com/rusty-snake) <print_hello_world+License@protonmail.com>
#
# Permission is hereby granted, free of charge, to any person obtaining a copy
# of this software and associated documentation files (the "Software"), to deal
# in the Software without restriction, including without limitation the rights
# to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
@rusty-snake
rusty-snake / touch-to-move.py
Last active July 2, 2019 09:39
ev3dev: python3-ev3dev2: A pogramm to steer a robot with two touch-sensors.
#!/usr/bin/env python3
#
# MIT License
#
# Copyright (c) 2018 rusty-snake (https://github.com/rusty-snake) <print_hello_world+License@protonmail.com>
#
# Permission is hereby granted, free of charge, to any person obtaining a copy
# of this software and associated documentation files (the "Software"), to deal
# in the Software without restriction, including without limitation the rights