When you get bored, simply take raw action. Do something beneficial for your future.
When I catch myself feeling bored, literally having nothing to do, I have fully adapted the mindset after months of disciplining myself to take raw actions, instead of doing nothing but brainlessly scrolling. Adapt this skill, since it will set you up for future success. As soon as you catch yourself scrolling, drop the fucking phone, and ask yourself whats the literal point of this.