What exactly is history when we talk about a 'state variable'? 
'state variable' - its value depends only on the given state of the system not on history i.e. not the 'path' taken to arrive at that state

While my book does try to explain what 'history' is, it really isn't clear to me. What exactly is the 'path' a system takes while getting to a state?
And heat isn't a state variable so how does history affect heat?
 A: The easiest example would be for a system in which the beginning state is a weight sitting on the floor and the end state is that same weight sitting on top of a table nearby. We can imagine different paths that we can take in getting the weight off the floor and placing it up on the table; these different paths are its "history".
In one history we simply lift the weight in a long series of tiny increments, millimeter by millimeter until it is at exactly the height of the tabletop.
Another history would be we we hitch the weight to a balloon, loft it to 100,000 feet of altitude, and then lower it back down to the elevation of the tabletop.
Another would be we lower the weight into a mine shaft 10 miles deep, then lift it all the way back up to the elevation of the tabletop. Or we put the weight into the trunk of our car, drive it to El Paso and back, and then put it on the tabletop.
In each case the only difference between the starting and ending states is the difference in gravitational potential energy between them. The trips to 100,000 feet, or to minus ten miles, and the El Paso excursion have no influence on the potential energy difference. This is called path independence.
A: 
What exactly is the 'path' a system takes while getting to a state?

There are an infinite number of possible equilibrium states of a system. The PV diagram in FIG 1 below shows just two such states, 1 and 2. Each different equilibrium state consists of a unique set of system properties. Shown are pressure, volume, temperature, internal energy and entropy (only pressure and volume are on the graph).
The equilibrium state of the system can be made to change by energy transfers between the system and its surroundings in the form of heat $Q$ and/or work $W$. The following first law equation for a closed system (no mass transfer) provides the relationship between work and heat and the change in internal energy from state 1 to state 2:
$$U_{2}-U_{1}=Q_{12}-W_{12}$$
The path by which the system below underwent a change in equilibrium from state 1 and 2 can be considered the "history" of the system in reaching state 2 from state 1. Note, however, there are an infinite number of possible paths from state 1 to 2, yet the the properties of state 2 will be the same for each path. For this reason, we say the state of the system does not depend on its history.

And heat isn't a state variable so how does history affect heat?

Actually, it's heat, in combination with work, that defines the history.
FIG 2 shows two alternative reversible paths (alternative "histories") for an ideal gas between states 1 and 2. Path 1-1A-2 is a constant pressure process followed by a constant volume process. Path 1-1B-2 is a constant volume process followed by a constant pressure process. The two paths involve different amounts of work (area under each path) and heat, yet they lead to the same final equilibrium state. Thus the properties at state 2, or any equilibrium state, are independent of the history of the system.
Hope this helps.

A: 
While my book does try to explain what 'history' is, it really isn't clear to me. What exactly is the 'path' a system takes while getting to a state?

The "path" refers to the path through the space of whatever variables are relevant to the process under consideration.
For example, if you are working with variables entropy $S$ and volume $V$, then you can consider different paths from, say, the point $(S_1, V_1)$ to the point $(S_2, V_2)$.
For example, one path could be a continuous straight line from $(S_1, V_1)$ to $(S_2, V_2)$, which can be parametrized by a single real number $x$ running from $0$ to $1$, like:
$$
S(x) = S_1 (1 - x) + x S_2
$$
$$
V(x) = V_1 (1 - x) + x V_2
$$
For example, another path could be a different set of straight line segments like:
$$
S(x) = S_1 (1 - 2 x) + 2 x S_2 \;\;\;\; (0\leq x \leq 1/2)
$$
$$
V(x) = V_1 \;\;\;\; (0\leq x \leq 1/2)
$$
$$
S(x) = S_2 \;\;\;\; (1/2\lt x \leq 1)
$$
$$
V(x) = 2 V_1 (1 - x) - V_2 (1 - 2x)  \;\;\;\; (1/2\lt x \leq 1)
$$
Clearly, there are infinitely many different paths between the two points.

And heat isn't a state variable so how does history affect heat?

The effect will be different depending on the different paths. We are simply not guaranteed that there is any function that specifies the heat $Q$ and depends only on $S$ and $V$, which is completely unlike the energy $U(S,V)$, which we know can be written as a function of $S$ and $V$.
The change in energy will always be:
$$
\Delta U = U(S_2, V_2) - U(S_1, V_1)\;,
$$
regardless of what path is taken.
The heat can be different depending on the different path taken from $(S_1, V_1)$ to $(S_2, V_2)$.
A: Let's view it stochastically: Then, we can model the situation as a stochastic process $(X_t)_{t \in [0, t_E]}$, adapted to a filtration $(F_t)_{t \in [0, t_E]}$.
At a given time point $t_* \in [0, t_E]$, the state (seen as a random variable) $X_{t_*}$ does not depend on history, that is for every $A \in F_{t_*}$, the condition $$P(X_{t_*} \in A) = P(X_{t_*} \in A \mid F_s)$$ for $0 \leq s < t$ holds.
In other words: Conditioning upon old filtrations / knowledge does not give us more information.
